Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Mar 03 2017 15:52
    @dom96 banned @Octopoda7
  • Feb 12 2017 23:57
    @dom96 banned @zzz125
  • Dec 23 2016 19:43
    @dom96 banned @Izrab
From IRC (bridge bot)
@FromIRC
<FromDiscord_> <me2beats> so can I just import strformat instead of strfmt?
<FromDiscord_> <me2beats> to make that platformer work
From IRC (bridge bot)
@FromIRC
<FromDiscord_> <me2beats> I think yes because now I have "undeclared identifier 'interp'" in this line interp"${mins:02}:${secs:02}"
<luis_> Hi everyone, are you aware whether someone implemented logistic regression in Nim? Not for machine learning but for simpler inferences...
From IRC (bridge bot)
@FromIRC
<luis_> How do I type cast to float?
<luis_> say from string?
Aditya Siram
@deech
The use of when in the documentation seems to imply that fieldPairs is a compile time only construct can anyone verify if this is true? https://nim-lang.org/docs/iterators.html#fieldPairs.i%2CT
From IRC (bridge bot)
@FromIRC
<Zevv> afaik it is, it is not really an iterator, iirc it just transforms your for loop into linear code
Aditya Siram
@deech
So am I correct in assuming this is compile time reflection, as in the object's field names aren't around at runtime?
From IRC (bridge bot)
@FromIRC
<Zevv> I think that's correct
<Zevv> you won't find them as strings in the C code, for example
Aditya Siram
@deech
Ok good, thanks!
From IRC (bridge bot)
@FromIRC
<FromDiscord_> <me2beats> well I made the platformer example run (yay) but still can't get what's wrong in ths line: interp"${mins:02}:${secs:02}"
<FromDiscord_> <me2beats> undeclared identifier 'interp
Varriount
@Varriount
Hello fellow Nimsters! How are things going?
Vindaar
@Vindaar
@me2beats the problem is that while the functionality of strfmt is basically the same as strformat from the stdlib, the naming is not. See the docs here: https://nim-lang.github.io/Nim/strformat.html
so replace interp by fmt or &
From IRC (bridge bot)
@FromIRC
<FromDiscord_> <me2beats> seems to work, cool! thank you
From IRC (bridge bot)
@FromIRC
<FromDiscord_> <DeltaPHC> Within pure Nim code, assuming you don't use ptr nor compile with checks disabled, is it still possible to trigger undefined behavior?
<FromDiscord_> <DeltaPHC> I know there have been recent efforts to make things safer, so I'm kinda wondering where things are at
<FromDiscord_> <DeltaPHC> I'm thinking that threading can still throw a wrench in things, but let's ignore that for a sec :⁠P
From IRC (bridge bot)
@FromIRC
<shashlick> Not bad - 1250 words in 3 hours
<Zevv> you're a slow reader!
<xace> shashlick: do you have a link to your blog or do I have to wait until the article is completed?
From IRC (bridge bot)
@FromIRC
<shashlick> First draft really
<shashlick> I will post it after some time for review
<shashlick> Hope to get it on the nim lang blog, let's see
Mamy Ratsimbazafy
@mratsim
@deech you can use astToStr if you need the field names
From IRC (bridge bot)
@FromIRC
<FromDiscord_> <me2beats> let me clarify pls - is this the official Nim discord server?
<FromDiscord_> <Shield> Yes
<FromDiscord_> <me2beats> thanks
liuxiaodong
@gogolxdong
koch --latest nimble also works for my issue , thanks.
From IRC (bridge bot)
@FromIRC
<shashlick> What are you seeing
Aditya Siram
@deech
IIUC method is a runtime dispatch construct so some type information must be kept around at runtime, is there any documentation that specifies what and when that happens?
liuxiaodong
@gogolxdong
the error has gone.
Vindaar
@Vindaar
@deech the only place I'm aware of that mentions RTTI at all is the typeinfo module: https://nim-lang.github.io/Nim/typeinfo.html
I'm off to bed now. Good night :)
From IRC (bridge bot)
@FromIRC
<xace> could someone help explain what happens on this line: https://github.com/kitsunyan/pakku/blob/1f6a5c6188a80bab511f56cb36eae824765c89d6/src/feature/syncinstall.nim#L312 # my understanding is that editorEnv is a string variable. What happens when you just put the string variable like that?
From IRC (bridge bot)
@FromIRC
<xace> oh, nvm now i see that it's part of a if-statement
liuxiaodong
@gogolxdong
D:\Nim\lib\system\jssys.nim(53, 6) Error: 'getCurrentException' is not GC-safe as it accesses 'lastJSError' which is a global using GC'ed memory
when compile nimx with task nake js
Luke Parker
@kayabaNerve
Use except Exception as e
From IRC (bridge bot)
@FromIRC
<owl_000> what enum {.pure.} pragma does? i added {.pure.} and can't find any differences.
<owl_000> and is enum values can be only string?
Zachary Carter
@zacharycarter
owl_000: pure forces you to address enum values as EnumName.EnumValue
From IRC (bridge bot)
@FromIRC
<Zevv> .pure. enums allow for names to collide
Zachary Carter
@zacharycarter
to allow for ^
From IRC (bridge bot)
@FromIRC
<Zevv> @zacharycarter: you're not forced to qualify
Zachary Carter
@zacharycarter
oh? I thought you were
From IRC (bridge bot)
@FromIRC
<Zevv> only for non-unique values
Zachary Carter
@zacharycarter
ah okay
From IRC (bridge bot)
@FromIRC
<livcd> good morning