Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Codegen: fail to generate 'if' when one of the branches has no type #2

Closed
waj opened this issue Dec 10, 2012 · 1 comment
Closed

Codegen: fail to generate 'if' when one of the branches has no type #2

waj opened this issue Dec 10, 2012 · 1 comment

Comments

@waj
Copy link
Member

waj commented Dec 10, 2012

def foo
end

if false
  foo
else
  1
end
@asterite
Copy link
Member

I think we should make empty functions and while loops have the Nil type, instead of void. Later we can optimize those functions to return void if they are not assigned to something.

@waj waj closed this as completed Dec 26, 2012
asterite pushed a commit that referenced this issue Feb 1, 2015
straight-shoota referenced this issue in straight-shoota/crystal Oct 15, 2017
# This is the 1st commit message:

Add formatter and parser for standards ISO8601, RFC1123, RFC2822

# The commit message #2 will be skipped:

# Prefer RFC 3339 instead of ISO 8601
#
# see https://stackoverflow.com/questions/522251/whats-the-difference-between-iso-8601-and-rfc-3339-date-formats and http://docs.diesel.rs/chrono/struct.DateTime.html#method.parse_from_rfc3339

# The commit message crystal-lang#3 will be skipped:

# Remove RFC 1123 in favour of RFC 2822
straight-shoota referenced this issue in straight-shoota/crystal Oct 15, 2017
# This is the 1st commit message:

Add formatter and parser for standards ISO8601, RFC1123, RFC2822

# The commit message #2 will be skipped:

# Prefer RFC 3339 instead of ISO 8601
#
# see https://stackoverflow.com/questions/522251/whats-the-difference-between-iso-8601-and-rfc-3339-date-formats and http://docs.diesel.rs/chrono/struct.DateTime.html#method.parse_from_rfc3339

# The commit message crystal-lang#3 will be skipped:

# Remove RFC 1123 in favour of RFC 2822
oprypin pushed a commit to oprypin/crystal that referenced this issue Sep 9, 2019
jan-zajic added a commit to jan-zajic/crystal that referenced this issue Nov 16, 2019
jan-zajic added a commit to jan-zajic/crystal that referenced this issue Jan 2, 2020
jan-zajic added a commit to jan-zajic/crystal that referenced this issue Jan 2, 2020
jan-zajic added a commit to jan-zajic/crystal that referenced this issue Jan 6, 2020
jan-zajic added a commit to jan-zajic/crystal that referenced this issue Apr 8, 2020
threez added a commit to threez/crystal that referenced this issue Jul 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants