From: nobu@ruby-lang.org
To: ruby-core@ruby-lang.org
Subject: [ruby-core:91775] [Ruby trunk Misc#15654] Documentation for Complex is wrong or misleading
Date: Mon, 11 Mar 2019 12:02:28 +0000 (UTC) [thread overview]
Message-ID: <redmine.journal-77052.20190311115559.6fcffd4eae0fdffd@ruby-lang.org> (raw)
In-Reply-To: redmine.issue-15654.20190311084336@ruby-lang.org
Issue #15654 has been updated by nobu (Nobuyoshi Nakada).
There would be a chance to optimize such expressions, but it is not a single literal syntactically, and constant folding is disabled in Ruby for its dynamic nature.
New literal syntax will be needed for an (impurely) imaginary number literal, but I doubt that we really need it.
----------------------------------------
Misc #15654: Documentation for Complex is wrong or misleading
https://bugs.ruby-lang.org/issues/15654#change-77052
* Author: sawa (Tsuyoshi Sawada)
* Status: Open
* Priority: Normal
* Assignee:
----------------------------------------
The documentation for `Complex` https://ruby-doc.org/core-2.6/Complex.html says or implies that a complex can be created by literal like `2+1i`, but that is actually calling the method `+` on receiver `2` with argument `1i`. The description should be changed to make it clear that `2+ 1i` is not a literal but is applying a method.
--
https://bugs.ruby-lang.org/
prev parent reply other threads:[~2019-03-11 12:03 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <redmine.issue-15654.20190311084336@ruby-lang.org>
2019-03-11 8:47 ` [ruby-core:91766] [Ruby trunk Misc#15654] Documentation for Complex is wrong or misleading sawadatsuyoshi
2019-03-11 9:19 ` [ruby-core:91768] " hanmac
2019-03-11 9:28 ` [ruby-core:91769] " sawadatsuyoshi
2019-03-11 9:32 ` [ruby-core:91770] " hanmac
2019-03-11 12:02 ` nobu [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.ruby-lang.org/en/community/mailing-lists/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=redmine.journal-77052.20190311115559.6fcffd4eae0fdffd@ruby-lang.org \
--to=ruby-core@ruby-lang.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).