Skip to content

Commit

Permalink
runtime(doc): fix typo in change.txt
Browse files Browse the repository at this point in the history
Signed-off-by: Christian Brabandt <cb@256bit.org>
  • Loading branch information
chrisbra committed Dec 8, 2023
1 parent 6863084 commit e06f2b4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions runtime/doc/change.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
*change.txt* For Vim version 9.0. Last change: 2023 Nov 15
*change.txt* For Vim version 9.0. Last change: 2023 Dec 08


VIM REFERENCE MANUAL by Bram Moolenaar
Expand Down Expand Up @@ -453,7 +453,7 @@ Note that when 'nrformats' includes "octal", decimal numbers with leading
zeros cause mistakes, because they can be confused with octal numbers.

Note similarly, when 'nrformats' includes "bin", binary numbers with a leading
'0x' or '0X' can be interpreted as hexadecimal rather than binary since '0b'
'0b' or '0B' can be interpreted as hexadecimal rather than binary since '0b'

This comment has been minimized.

Copy link
@k-takata

k-takata Dec 19, 2023

Member

I'm thinking whether this change is correct.

I think what the original sentence wanted to say might be:

Note similarly, when 'nrformats' includes both "bin" and "hex", binary numbers with a leading
'0x' or '0X' can be interpreted as hexadecimal rather than binary since '0b'
are valid hexadecimal digits. (E.g. CTRL-A on "0x0b11" results in "0x0b12", not "0x0b100".)

This comment has been minimized.

Copy link
@chrisbra

chrisbra Dec 19, 2023

Author Member

yes, but binary numbers cannot start with 0x right?

This comment has been minimized.

Copy link
@k-takata

k-takata Dec 19, 2023

Member

Right, but binary numbers with a leading '0b' cannot be interpreted as hexadecimal unless it starts with '0x'.
Both the original text and your text look incorrect (or misleading).

This comment has been minimized.

Copy link
@chrisbra

chrisbra Dec 19, 2023

Author Member

I played around with this a bit. It seems, numbers starting with 0x0b will always be detected as hexadecimal. I cannot make numbers starting with 0b detect as hex, not even when there are non-binary numbers included. So it seems like you are right. Can you send a doc-patch please?

are valid hexadecimal digits.

When the number under the cursor is too big to fit into 32 or 64 bit
Expand Down

0 comments on commit e06f2b4

Please sign in to comment.