<FromGitter>
<luislavena> @bew use `CRYSTAL_PATH` environment variable, a colon-separated list of relative/absolute paths is expected. see `crystal env` for default one.
<FromGitter>
<bew> oh perfect, ty!
<FromGitter>
<bew> I can't find in the doc, and don't remember where to search, what is the CR equivalent to a C NULL pointer?
<FromGitter>
<bew> thx, finally I figured it out with: `Pointer(Int32).null`
<FromGitter>
<bew> or simply `Pointer(Int32).new 0_u64`
bjz has quit [Ping timeout: 240 seconds]
Philpax_ has joined #crystal-lang
<FromGitter>
<bew> I have another question tough: with `--prelude=empty` I still can't declare `Array` as a `struct`, it complains with: `Array is not a struct, it's a generic class`, any iea?
<FromGitter>
<bew> idea*
<FromGitter>
<bew> (I didn't found this error in the compiler sources :/)
Philpax has quit [Ping timeout: 255 seconds]
<FromGitter>
<mjago> @bew array is included in prelude so maybe need your own mini prelude?
<FromGitter>
<Sija> @bew see `src/compiler/crystal/semantic/top_level_visitor.cr`
<FromGitter>
<bew> @mjago I used `--prelude=empty` so no array in this one, @Sija I'll look
<FromGitter>
<Sija> IIRC `Array` and some other stdlib classes are defined internally by the compiler but I could be wrong
<FromGitter>
<mjago> @bew oh I see - read your question wrong !
<FromGitter>
<bew> exactly, just found them myself, but ty
<FromGitter>
<bew> 2 questions: 1/ What are `MetaVars` ? 2/ If I subclass `Program` and redefine `Program#initialize` I could redeclare all native types ?
<FromGitter>
<bew> (2/ ... and make my own compiler, etc..)
Philpax has joined #crystal-lang
Philpax_ has quit [Ping timeout: 245 seconds]
Hates_ has left #crystal-lang [#crystal-lang]
<FromGitter>
<eliasjpr> Is there anyway to turn a string into a constant?"
<FromGitter>
<eliasjpr> Something like "SomeClass" to SomeClass where I can call SomeClass.new
<FromGitter>
<sdogruyol> @eliasjpr you can do that with a macro
<FromGitter>
<eliasjpr> okay, I guess I was approaching it the right way, I was wondering if there was a built in macro already
<crystal-gh>
[crystal] MakeNowJust opened pull request #4285: p: not display if no object is given (master...fix/p/empty-display) https://git.io/vSSFM
jokke1 has joined #crystal-lang
bjmllr has quit [*.net *.split]
kragniz has quit [*.net *.split]
fedruantine has quit [*.net *.split]
jokke has quit [*.net *.split]
aarongodin has quit [*.net *.split]
bjmllr has joined #crystal-lang
gloscombe has joined #crystal-lang
aarongodin_ is now known as aarongodin
<FromGitter>
<chuckremes> @bew I’ll be putting some work into it the next few days as I figure things out on my end. Really liking crystal but so much of what I do relies on lots of meta-magic. :)
<FromGitter>
<bew> ahah! did you see the video (on vimeo iirc) on advanced macros ? I think you should add a link to it in you page as this is very important to not abuse macro (I can search for the link if you want)
<FromGitter>
<bew> @chuckremes
greengriminal has quit [Quit: This computer has gone to sleep]
<FromGitter>
<chuckremes> @bew If you have the link I’d love to see it.
bjz_ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Raimondii has joined #crystal-lang
Raimondi has quit [Ping timeout: 268 seconds]
Raimondii is now known as Raimondi
bjz has joined #crystal-lang
LastWhisper____ has joined #crystal-lang
bjz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Yxhuvud has quit [Read error: Connection reset by peer]
Yxhuvud has joined #crystal-lang
<zipR4ND>
hey all
<zipR4ND>
a word: how to clone a class with circular dependencies?
<zipR4ND>
class Test; @t : Test; end;
A124 has quit [Quit: '']
A124 has joined #crystal-lang
greengriminal has quit [Quit: Leaving]
<FromGitter>
<elorest> Is there a way to use `crystal play` with codemirrors vim mode?
<FromGitter>
<elorest> how blocks in crystal are different from ruby. despite reading the docs on blocks and procs a few times I don’t really understand the difference between {} and do end. I see that {} work in this case but do end don’t. I would I write my method that takes a block so that do end would work? https://play.crystal-lang.org/#/r/1uya
<FromGitter>
<l3kn> seems like the second version is being interpreted as `puts(wrap_in_tags("title", "hello")) do |html| ...`
<FromGitter>
<l3kn> I don't think there is anything wrong with your method
ragmaanir has joined #crystal-lang
<FromGitter>
<g33kidd> Does crystal support something like this: `something, do: "hello"` ? If not, would it be possible to create a method that does allow this?