Crystal Lang > Ruby > Python

Crystal Lang > Ruby > Python

Why choose the inferior Ruby and Python when you have Crystal.
It's Basically Ruby on sterioids.

Other urls found in this thread:

juliacomputing.com/blog/2016/02/09/static-julia.html
twitter.com/NSFWRedditImage

>Why choose the inferior Ruby and Python when you have Crystal.
Because they are actually finished unlike Crystal.
/thread

>finish unlike cystal
Are you sure about that?

because I'd rather import solution and get on with my life than rewrite extant libraries in the meme language du jour

>jerking off to typos

because no tutorials
because no libs
because no frameworks
because no wrappers

A ruby tutorial will serve you the save.

same*

That's unfortunately untrue.
t. Crystal and Ruby user

How's that untrue ?

The type system alone makes too much of a difference.

I see where you are coming from there,
But you can't overlook how close it still is to Ruby.

If the Crystal devs made Crystal 100% compatible with Ruby, then it would replace MRI Ruby and be the new Ruby standard. I dont see why the Crystal devs dont do this.

Wouldn't be a bad idea to suggest that to them, It'll be a pretty good idea if it gets put into action.

Maybe it would compromise performance?

Lovely language, but it can't build shared objects and lacks an OTP clone.

Even syntactically there are enough differences caused by the type system, like:
# ruby
def hasDefaultParameters(bla: 123)

# crystal
def hasDefaultParameters(bla :Int32 = 123)


If it was 100% compatible, the devs wouldn't gain anything from using LLVM.

Plus threading support isn't there, the type system just assumes object attributes as thread unsafe which causes some surprising required typecast.

>If it was 100% compatible, the devs wouldn't gain anything from using LLVM.
Why? That doesnt make any sense. Its possible to use any backend for Ruby, it doesnt change Ruby as a language.

They tried it, but couldn't make it work.

Julia is a scripting language that uses the LLVM backend, so it is possible, the Crystal devs are just not good enough compiler writers.

Making dynamically typed (and other dynamic features) languages fast requires a JIT compiler.
LLVM is too slow as JIT compiler backend which is why almost any JIT compiler community has given up on LLVM as a backend.

Besides, there are other, more promising and complete projects like Rubinius and JRuby9000.

Meme language is meme language. At least Pony offered something interesting like capabilities and actors. WTF is crystal offering?

>so it is possible, the Crystal devs are just not good enough compiler writers.
No.
Julia was designed the way that it requires little recompilation later on because despite the dynamic type system it allows the compiler to assume a lot.
See juliacomputing.com/blog/2016/02/09/static-julia.html

>WTF is crystal offering?
A native RAD language that isn't crippled like golang.

BUMP
I'm curious about this language

I was disappointed to learn Pony didn't have preemption.

Ok.
Here is how some stuff works:

aVariable = "OP"
# type of a Variable is inferred to String

arrVariable: [] of String = ["is", "a", "fag"]
# generic types require type declarations for the reason of enhanced compilation speed

if someCondition
bVariable = "Really."
end
# type of bVariable is inferred as String | Nil to mimic Ruby's code flow

# the same applies to attributes:

class SomeClass
def initialize(someVar : String) # arguments require type declarations for the reason of enhanced compilation speed
@x = someVar # type is String
end

def somethingElse
@y = 2 # type is String | Nil, since y wasn't mentioned in the constructor
end
end

Somewhat off-topic, but why is Crystal moving so much faster than Nim? Is it just that they have more/better developers, or did Nim cripple itself somehow?

Why doesn't someone just create a cross-platform easy to use language that is like python but faster?

Define "like Python".

I don't see how Crystal is moving faster.

However, by creating a to-C compiler and relying on this backend and its leaky abstractions the nim devs built their house on sand and showed they lack compiler knowledge, so I wouldn't wonder if there is a lack of progress.

have you seen Nim's website

seriously tho

As in like Python but with a static type system and immutable types but still with shitty hacks like def someMethod(self): ?