Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Numeric constant

Øyvind Kallstad edited this page Sep 14, 2017 · 2 revisions

Real numbers (float)

Real numbers are numbers that conform to one of the following forms:

  • [+|-] digits . digits [e [(+|-)] digits] [(d|l)] [(kb|mb|gb|tb|pb)]
  • [(+|-)] . digits [e [(+|-)] digits] [(d|l)] [(kb|mb|gb|tb|pb)]
  • [(+|-)] digits . [e [(+|-)] digits] [(d|l)] [(kb|mb|gb|tb|pb)]
  • [(+|-)] digits [e [(+|-)] digits] [(d|l)] [(kb|mb|gb|tb|pb)]
Example
-999e-10dmb
+6.e-6lkb
+.6
-.9e+5dmb
.6tb
+4.9e+5dmb
4.5
-9.9
+7.4

Scopes

The following scopes are assigned to real numbers:

  • constant.numeric.real

Integers

Integers are numbers that conform to the following form:

  • [(+|-)] digits [(d|l)] [(kb|mb|gb|tb|pb)]
Example
7
-100
+73kb

Scopes

The following scopes are assigned to real numbers:

  • constant.numeric.integer

Hexadecimal numbers

Hexadecimal numbers are numbers that conform to the following form:

  • 0x 0-f [l] [kb|mb|gb|tb|pb]
Example
0x9
0x25l

Scopes

The following scopes are assigned to real numbers:

  • constant.numeric.hex

Home

About

Use

Contributing

Scopes and Tokens

Clone this wiki locally

Morty Proxy This is a proxified and sanitized view of the page, visit original site.