
    h                        % S SK r S SKrS SKrS SKJrJrJrJrJrJ	r	J
r
JrJrJr  S SKrS SKJr  Sq\	\R$                     \S'    " S S\ R(                  5      rSSSSSSSSSSSS.S	\S
\	\   S\S\	\\\\4   /\4      S\	\\/\4      S\	\\/\4      S\	\\/\4      S\S\	\\\\\4      /\4      S\S\S\	\   S\4S jjrSSSSSSSSSSSS.S\S
\	\   S\S\	\\\\4   /\4      S\	\\/\4      S\	\\/\4      S\	\\/\4      S\S\	\\\\\4      /\4      S\S\S\	\   4S jjrSSSSSSSSSSSS.S\S
\	\   S\S\	\\\\4   /\4      S\	\\/\4      S\	\\/\4      S\	\\/\4      S\S\	\\\\\4      /\4      S\S\S\	\   4S jjrS rS\\\\\4      /\4   4S jrSSSSSSSSSSSS\R<                  S.S\S	\S \S!\S"\S#\S\	\S$      S%\	\\\4      S&\	\\\4      S'\	\\/\4      S(\S)\S*\S\S+\4S, jjrSSSSSSSSSSSS\R<                  S.S\S \S!\S"\S#\S\	\S$      S%\	\\\4      S&\	\\\4      S'\	\\/\4      S(\S)\S*\S\S+\4S- jjr  " S. S$5      r!S\4S/ jr"g)0    N)
AnyCallableIOIterableMappingOptionalSetTupleTypeUnion)Parser_reserved_word_rec                   (    \ rS rSrSrSrSrSrSrSr	g)	
QuoteStyle'   a*  Controls how strings will be quoted during encoding.

By default, for compatibility with the `json` module and older versions of
`json5`, strings (not being used as keys and that are legal identifiers)
will always be double-quoted, and any double quotes in the string will be
escaped. This is `QuoteStyle.ALWAYS_DOUBLE`.  If you pass
`QuoteStyle.ALWAYS_SINGLE`, then strings will always be single-quoted, and
any single quotes in the string will be escaped.  If you pass
`QuoteStyle.PREFER_DOUBLE`, then the behavior is the same as ALWAYS_DOUBLE
and strings will be double-quoted *unless* the string contains more double
quotes than single quotes, in which case the string will be single-quoted
and single quotes will be escaped. If you pass `QuoteStyle.PREFER_SINGLE`,
then the behavior is the same as ALWAYS_SINGLE and strings will be
single-quoted *unless* the string contains more single quotes than double
quotes, in which case the string will be double-quoted and any double
quotes will be escaped.

*Note:* PREFER_DOUBLE and PREFER_SINGLE can impact performance, since in
order to know which encoding to use you have to iterate over the entire
string to count the number of single and double quotes. The codes guesses
at an encoding while doing so, but if it guess wrong, the entire string has
to be re-encoded, which will slow things down. If you are very concerned
about performance (a) you probably shouldn't be using this library in the
first place, because it just isn't very fast, and (b) you should use
ALWAYS_DOUBLE or ALWAYS_SINGLE, which won't have this issue.
always_doublealways_singleprefer_doubleprefer_single N)
__name__
__module____qualname____firstlineno____doc__ALWAYS_DOUBLEALWAYS_SINGLEPREFER_DOUBLEPREFER_SINGLE__static_attributes__r       \C:\Users\julio\OneDrive\Documentos\Trabajo\Ideas Frescas\venv\Lib\site-packages\json5/lib.pyr   r   '   s    6 $M#M#M#Mr!   r   Tencodingclsobject_hookparse_float	parse_intparse_constantstrictobject_pairs_hookallow_duplicate_keysconsume_trailingstartfpr$   r%   r&   r'   r(   r)   r*   r+   r,   r-   r.   returnc                x    U R                  5       n[        UUUUUUUUUU	U
US9u  pnU(       a  [        U5      eU$ )a  Deserialize ``fp`` (a ``.read()``-supporting file-like object
containing a JSON document) to a Python object.

Supports almost the same arguments as ``json.load()`` except that:
    - the `cls` keyword is ignored.
    - an extra `allow_duplicate_keys` parameter supports checking for
      duplicate keys in a object; by default, this is True for
      compatibility with ``json.load()``, but if set to False and
      the object contains duplicate keys, a ValueError will be raised.
    - an extra `consume_trailing` parameter specifies whether to
      consume any trailing characters after a valid object has been
      parsed. By default, this value is True and the only legal
      trailing characters are whitespace. If this value is set to False,
      parsing will stop when a valid object has been parsed and any
      trailing characters in the string will be ignored.
    - an extra `start` parameter specifies the zero-based offset into the
      file to start parsing at. If `start` is None, parsing will
      start at the current position in the file, and line number
      and column values will be reported as if starting from the
      beginning of the file; If `start` is not None,
      `load` will seek to zero and then read (and discard) the
      appropriate number of characters before beginning parsing;
      the file must be seekable for this to work correctly.

You can use `load(..., consume_trailing=False)` to repeatedly read
values from a file. However, in the current implementation `load` does
this by reading the entire file into memory before doing anything, so
it is not very efficient.

Raises
    - `ValueError` if given an invalid document. This is different
      from the `json` module, which raises `json.JSONDecodeError`.
    - `UnicodeDecodeError` if given a byte string that is not a
      legal UTF-8 document (or the equivalent, if using a different
      `encoding`). This matches the `json` module.
r#   )readparse
ValueError)r/   r$   r%   r&   r'   r(   r)   r*   r+   r,   r-   r.   svalerr_s                   r"   loadr9   I   sV    l 		A	%+1)KCa oJr!   r5   c                X    [        U UUUUUUUUU	U
US9u  pnU(       a  [        U5      eU$ )a  Deserialize ``s`` (a string containing a JSON5 document) to a Python
object.

Supports the same arguments as ``json.load()`` except that:
    - the `cls` keyword is ignored.
    - an extra `allow_duplicate_keys` parameter supports checking for
      duplicate keys in a object; by default, this is True for
      compatibility with ``json.load()``, but if set to False and
      the object contains duplicate keys, a ValueError will be raised.
    - an extra `consume_trailing` parameter specifies whether to
      consume any trailing characters after a valid object has been
      parsed. By default, this value is True and the only legal
      trailing characters are whitespace. If this value is set to False,
      parsing will stop when a valid object has been parsed and any
      trailing characters in the string will be ignored.
    - an extra `start` parameter specifies the zero-based offset into the
      string to start parsing at.

Raises
    - `ValueError` if given an invalid document. This is different
      from the `json` module, which raises `json.JSONDecodeError`.
    - `UnicodeDecodeError` if given a byte string that is not a
      legal UTF-8 document (or the equivalent, if using a different
      `encoding`). This matches the `json` module.
)r5   r$   r%   r&   r'   r(   r)   r*   r+   r,   r-   r.   )r3   r4   )r5   r$   r%   r&   r'   r(   r)   r*   r+   r,   r-   r.   r6   r7   r8   s                  r"   loadsr;      sK    V 
%+1)KCa oJr!   c          
      z   Ub   S5       e[        U [        5      (       a  U=(       d    SnU R                  U5      n U (       d  [        S5      eU=(       d    Sn[	        U SUS9nUR                  XzS.S	9u  pnU(       a  SX4$  [        UUUUUUU	S
9nUSU4$ ! [         a  nS[        U5      U4s SnA$ SnAff = f)a	  Parse ```s``, returning positional information along with a value.

This works exactly like `loads()`, except that (a) it returns the
position in the string where the parsing stopped (either due to
hitting an error or parsing a valid value) and any error as a string,
(b) it takes an optional `consume_trailing` parameter that says whether
to keep parsing the string after a valid value has been parsed; if True
(the default), any trailing characters must be whitespace. If False,
parsing stops when a valid value has been reached, (c) it takes an
optional `start` parameter that specifies a zero-based offset to start
parsing from in the string, and (d) the return value is different, as
described below.

`parse()` is useful if you have a string that might contain multiple
values and you need to extract all of them; you can do so by repeatedly
calling `parse`, setting `start` to the value returned in `position`
from the previous call.

Returns a tuple of (value, error_string, position). If the string
    was a legal value, `value` will be the deserialized value,
    `error_string` will be `None`, and `position` will be one
    past the zero-based offset where the parser stopped reading.
    If the string was not a legal value,
    `value` will be `None`, `error_string` will be the string value
    of the exception that would've been raised, and `position` will
    be the zero-based farthest offset into the string where the parser
    hit an error.

Raises:
    - `UnicodeDecodeError` if given a byte string that is not a
      legal UTF-8 document (or the equivalent, if using a different
      `encoding`). This matches the `json` module.

Note that this does *not* raise a `ValueError`; instead any error is
returned as the second value in the tuple.

You can use this method to read in a series of values from a string
`s` as follows:

>>> import json5
>>> s = '1 2 3 4'
>>> values = []
>>> start = 0
>>> while True:
...     v, err, pos = json5.parse(s, start=start, consume_trailing=False)
...     if v:
...         values.append(v)
...         start = pos
...         if start == len(s) or s[start:].isspace():
...             # Reached the end of the string (ignoring trailing
...             # whitespace
...             break
...         continue
...     raise ValueError(err)
>>> values
[1, 2, 3, 4]

Nz!Custom decoders are not supportedzutf-8z!Empty strings are not legal JSON5r   z<string>)pos)_strict_consume_trailing)global_vars)r&   r'   r(   r)   r+   r,   )
isinstancebytesdecoder4   r   r3   _convertstr)r5   r$   r%   r&   r'   r(   r)   r*   r+   r,   r-   r.   parserastr7   r=   valuees                     r"   r3   r3      s    V ;;;;;!U&wHHX<==JQEAzu-FLL &N ! MCc S~!##)/!5
 dC !SVS  !s   B 
B:"B5/B:5B:c                    ^^^ S nUUU4S jnU=(       d    [         nU=(       d    [        nU=(       d    Un[        XX#U5      $ )Nc                 X    [        U R                  SS5      R                  SS5      5      $ )NInfinityinfNaNnan)floatreplace)r5   s    r"   _fp_constant_parser%_convert.<locals>._fp_constant_parserD  s%    QYYz5199%GHHr!   c                    > T(       d:  [        5       nU  H*  u  p#X!;   a  [        SU S35      eUR                  U5        M,     T(       a  T" U 5      $ T(       a  T" [        U 5      5      $ [        U 5      $ )NzDuplicate key "z" found in object)setr4   adddict)pairskeyskeyr8   r,   r&   r+   s       r"   _dictify_convert.<locals>._dictifyG  sj    #5D;$se;L%MNN  
 $U++tE{++E{r!   )rP   int	_walk_ast)	rG   r&   r'   r(   r)   r+   r,   rR   r[   s	    `   ``  r"   rD   rD   ;  s>    I &K SI#:':NSKNKKr!   dictifyc           
         U S:X  a  g U S:X  a  gU S:X  a  gU u  pVUS:X  ai  UR                  S5      (       d  UR                  S5      (       a  U" US	S
9$ SU;   d  SU;   d  SU;   a  U" U5      $ SU;   d  SU;   a  U" U5      $ U" U5      $ US:X  a  U$ US:X  a4  / nU H$  u  p[        XX#U5      n
UR                  X45        M&     U" U5      $ US:X  a  U V s/ s H  n [        XX#U5      PM     sn $ [        SU -   5      es  sn f )NNoneTrueTFalseFnumber0x0X   )base.rI   ErL   rN   stringobjectarrayzunknown el: )
startswithr^   appendr4   )elr_   r'   r(   r)   tyvrX   rZ   val_exprr6   s              r"   r^   r^   \  s3    
V|	V|	W}EB	X~<<d!3!3QR((!8sax3!8q>!?eqj!!$$|	X~	X~MC;>C LL#$	 
 u~	W} 
 b;>J
 	
 ^b(
))	
s   C=F)skipkeysensure_asciicheck_circular	allow_nanr%   indent
separatorsdefault	sort_keys
quote_keystrailing_commasr,   quote_styleobjrt   ru   rv   rw   JSON5Encoderrx   ry   rz   r{   r|   r}   r~   c                V    UR                  [        SU UUUUUUUU	U
UUUUS.UD65        g)aL  Serialize ``obj`` to a JSON5-formatted stream to ``fp``,
a ``.write()``-supporting file-like object.

Supports the same arguments as ``dumps()``, below.

Calling ``dump(obj, fp, quote_keys=True, trailing_commas=False,                    allow_duplicate_keys=True)``
should produce exactly the same output as ``json.dump(obj, fp).``
)r   rt   ru   rv   rw   r%   rx   ry   rz   r{   r|   r}   r,   r~   Nr   )writedumps)r   r/   rt   ru   rv   rw   r%   rx   ry   rz   r{   r|   r}   r,   r~   kws                   r"   dumpr     sQ    : HH 	
%)!!+!5#	
 	
r!   c                ~    U=(       d    [         nU" SUUUUUUUU	U
UUUS.UD6nUR                  U [        5       SSS9$ )aJ  Serialize ``obj`` to a JSON5-formatted string.

Supports the same arguments as ``json.dumps()``, except that:

- The ``encoding`` keyword is ignored; Unicode strings are always written.
- By default, object keys that are legal identifiers are not quoted; if you
  pass ``quote_keys=True``, they will be.
- By default, if lists and objects span multiple lines of output (i.e.,
  when ``indent`` >=0), the last item will have a trailing comma after it.
  If you pass ``trailing_commas=False``, it will not.
- If you use a number, a boolean, or ``None`` as a key value in a dict, it
  will be converted to the corresponding JSON string value, e.g.  "1",
  "true", or "null". By default, ``dump()`` will match the `json` modules
  behavior and produce malformed JSON if you mix keys of different types
  that have the same converted value; e.g., ``{1: "foo", "1": "bar"}``
  produces '{"1": "foo", "1": "bar"}', an object with duplicated keys. If
  you pass ``allow_duplicate_keys=False``, an exception will be raised
  instead.
- If `quote_keys` is true, then keys of objects will be enclosed in quotes,
  as in regular JSON. Otheriwse, keys will not be enclosed in quotes unless
  they contain whitespace.
- If `trailing_commas` is false, then commas will not be inserted after the
  final elements of objects and arrays, as in regular JSON.  Otherwise,
  such commas will be inserted.
- If `allow_duplicate_keys` is false, then only the last entry with a given
  key will be written. Otherwise, all entries with the same key will be
  written.
- `quote_style` controls how strings are encoded. See the documentation
  for the `QuoteStyle` class, above, for how this is used.

  *Note*: Strings that are being used as unquoted keys are not affected
  by this parameter and remain unquoted.

  *`quote_style` was added in version 0.10.0*.

Other keyword arguments are allowed and will be passed to the
encoder so custom encoders can get them, but otherwise they will
be ignored in an attempt to provide some amount of forward-compatibility.

*Note:* the standard JSON module explicitly calls `int.__repr(obj)__`
and `float.__repr(obj)__` to encode ints and floats, thereby bypassing
any custom representations you might have for objects that are subclasses
of ints and floats, and, for compatibility, JSON5 does the same thing.
To override this behavior, create a subclass of JSON5Encoder
that overrides `encode()` and handles your custom representation.

For example:

```
>>> import json5
>>> from typing import Any, Set
>>>
>>> class Hex(int):
...    def __repr__(self):
...        return hex(self)
>>>
>>> class CustomEncoder(json5.JSON5Encoder):
...    def encode(
...        self, obj: Any, seen: Set, level: int, *, as_key: bool
...    ) -> str:
...        if isinstance(obj, Hex):
...            return repr(obj)
...        return super().encode(obj, seen, level, as_key=as_key)
...
>>> json5.dumps([20, Hex(20)], cls=CustomEncoder)
'[20, 0x14]'

```

*Note:* calling ``dumps(obj, quote_keys=True, trailing_commas=False,                             allow_duplicate_keys=True)``
should produce exactly the same output as ``json.dumps(obj).``
rt   ru   rv   rw   rx   ry   rz   r{   r|   r}   r,   r~   r   F)seenlevelas_keyr   )r   encoderU   )r   rt   ru   rv   rw   r%   rx   ry   rz   r{   r|   r}   r,   r~   r   encs                   r"   r   r     sg    x 
C
 !%'1 C ::cQu:==r!   c                      \ rS rSrSSSSSSSSSSS\R
                  S.S\S\S\S	\S
\\\	\
4      S\\\
\
4      S\\\/\4      S\S\S\S\S\4S jjrS\S\4S jrS\S\S\	S\S\
4
S jrS\S\S\\
   4S jrS\	S\S\
4S jrS\S\S\
4S jrS\
S\S\
4S jrS\
S\S\
4S jrS\
S\
4S  jrS\S\	S\
4S! jrS\S\S\	S\
4S" jrS\S\S\	S\
4S# jrS\	S\\
\
4   4S$ jrS%\
S\4S& jrS\
S\4S' jrS\
S\4S( jr S%\
S\4S) jr!S*r"g)+r   i%  FTNr   rt   ru   rv   rw   rx   ry   rz   r{   r|   r}   r,   r~   c                    AXl         X l        X0l        X@l        XPl        X`l        Uc  Uc  SOSnUu  U l        U l        U=(       d    [        U l	        Xl
        Xl        Xl        Xl        Xl        g)zProvides a class that may be overridden to customize the behavior
of `dumps()`. The keyword args are the same as for that function.
*Added in version 0.10.0N)z, : ),r   )rt   ru   rv   rw   rx   ry   item_separatorkv_separator_raise_type_error
default_fnr{   r|   r}   r,   r~   )selfrt   ru   rv   rw   rx   ry   rz   r{   r|   r}   r,   r~   r   s                 r"   __init__JSON5Encoder.__init__&  sq    ,  (,"$)/[J1;.T.!6%6"$.$8!&r!   r   r0   c                 $    U R                  U5      $ )a7  Provides a last-ditch option to encode a value that the encoder
doesn't otherwise recognize, by converting `obj` to a value that
*can* (and will) be serialized by the other methods in the class.

Note: this must not return a serialized value (i.e., string)
directly, as that'll result in a doubly-encoded value.)r   )r   r   s     r"   rz   JSON5Encoder.defaultN  s     s##r!   r   r   r   c                    U=(       d
    [        5       nU R                  XS9nUb  U$ U(       a  [        SU 35      eU R                  XU5      $ )aS  Returns an JSON5-encoded version of an arbitrary object. This can
be used to provide customized serialization of objects. Overridden
methods of this class should handle their custom objects and then
fall back to super.encode() if they've been passed a normal object.

`seen` is used for duplicate object tracking when `check_circular`
is True.

`level` represents the current indentation level, which increases
by one for each recursive invocation of encode (i.e., whenever
we're encoding the values of a dict or a list).

May raise `TypeError` if the object is the wrong type to be
encoded (i.e., your custom routine can't handle it either), and
`ValueError` if there's something wrong with the value, e.g.
a float value of NaN when `allow_nan` is false.

If `as_key` is true, the return value should be a double-quoted string
representation of the object, unless obj is a string that can be an
identifier (and quote_keys is false and obj isn't a reserved word).
If the object should not be used as a key, `TypeError` should be
raised; that allows the base implementation to implement `skipkeys`
properly.
r   zInvalid key f)rU   _encode_basic_type	TypeError_encode_non_basic_type)r   r   r   r   r   r5   s         r"   r   JSON5Encoder.encodeW  sU    @ }su##C#7=HmC5122**3e<<r!   c                8   [        U[        5      (       a  U R                  XS9$ USL a  U(       a  S$ S$ USL a  U(       a  S$ S$ Uc  U(       a  S	$ S
$ [        U[        5      (       a  U R	                  XS9$ [        U[
        5      (       a  U R                  XS9$ g)z/Returns None if the object is not a basic type.r   Tz"true"trueFz"false"falseNz"null"null)rA   rE   _encode_strr]   _encode_intrP   _encode_floatr   r   r   s      r"   r   JSON5Encoder._encode_basic_type  s     c3##C#77
 $;%8161%< &93G3;%8161c3##C#77c5!!%%c%99r!   c                J    [         R                  U5      nU(       a  SU S3$ U$ )N")r]   __repr__)r   r   r   r5   s       r"   r   JSON5Encoder._encode_int  s%    LL!1#Qx(q(r!   c                >   U[        S5      :X  a  U R                  nSnO_U[        S5      :X  a  U R                  nSnOA[        R                  " U5      (       a  U R                  nSnOSn[         R	                  U5      nU(       d  [        S5      eU(       a  SU S3$ U$ )	NrM   rL   z-infz	-InfinityrN   TzIllegal JSON5 value: f{obj}r   )rP   rw   mathisnanr   r4   )r   r   r   allowedr5   s        r"   r   JSON5Encoder._encode_float  s    %,nnGAE&M!nnGAZZ__nnGAGs#A:;;!1#Qx(q(r!   c                    U(       a?  U R                  U5      (       a)  U R                  (       d  U R                  U5      (       d  U$ U R                  XR                  5      $ )N)is_identifierr|   is_reserved_word_encode_quoted_strr~   r   s      r"   r   JSON5Encoder._encode_str  sJ    ""3''OO))#..J&&s,<,<==r!   c                    / nSnSnSnSnU GH
  nX:X  a>  US-  nU[         R                  [         R                  4;   a  U R                  U5      n	OUn	OX:X  a>  US-  nU[         R                  [         R
                  4;   a  U R                  U5      n	OrUn	OoUS:X  a  U R                  U5      n	OW[        U5      n
U
S:  a  U R                  U5      n	O4U
S:  a  Un	O+U R                  (       d	  US;  a  Un	OU R                  U5      n	UR                  U	5        GM     XE:  a4  U[         R                  :X  a   U R                  U[         R                  5      $ XT:  a4  U[         R
                  :X  a   U R                  U[         R                  5      $ U[         R                  [         R                  4;   a  SS	R                  U5      -   S-   $ SS	R                  U5      -   S-   $ )
z@Returns a quoted string with a minimal number of escaped quotes.r   'r      \       )u    u     )r   r   r   
_escape_chr   r   ordru   ro   r   join)r   r   r~   retdouble_quotes_seensingle_quotes_seensqdqch
encoded_chos              r"   r   JSON5Encoder._encode_quoted_str  s   Bx #a'",,,,#  "&!4J!#J"a'",,,,#  "&!4J!#Jt!__R0
Gr6!%!4JW!#J**r9M/M!#J!%!4JJJz"C J 3z777**3
0H0HII3z777**3
0H0HII:33Z5M5MNN%++RWWS\!C''r!   r   c                     US:X  a  gUS:X  a  gUS:X  a  gUS:X  a  gUS	:X  a  g
US:X  a  gUS:X  a  gUS:X  a  gUS:X  a  gUS:X  a  g[        U5      nUS:  a  SUS 3$ US-
  nSUS-	  -   nSUS-  -   nSUS SUS 3$ )z9Returns the backslash-escaped representation of the char.r   z\\r   z\'r   z\"
z\nz\r	z\tz\bz\fz\v z\0i   z\u04xi   
   i   i  )r   )r   r   r   r6   highlows         r"   r   JSON5Encoder._escape_ch  s    :99:::::::Gu93= 'k#e$T#JbS	**r!   c                    U R                   (       a,  [        U5      nXB;   a  [        S5      eUR                  U5        [	        US5      (       a'  [	        US5      (       a  U R                  XUS-   5      nO`[	        US5      (       a'  [	        US5      (       a  U R                  XUS-   5      nO(U R                  U R                  U5      X#S-   SS9nUc   eU R                   (       a  UR                  W5        U$ )NzCircular reference detected.rY   __getitem__r   __iter__Fr   )
rv   idr4   rV   hasattr_encode_dict_encode_arrayr   rz   remove)r   r   r   r   ir5   s         r"   r   #JSON5Encoder._encode_non_basic_type  s    
 3Ay !?@@HHQK
 3GC$?$?!!#UQY7AS-((WS*-E-E""3eai8ADLL-tQYuMA= =KKNr!   c                 f   U(       d  gU R                  U5      u  pEU R                  U-   nU R                  nU R                  (       a  [	        UR                  5       5      nOUR                  5       nSU-   n	Sn
[        5       nU H~  n U R                  XUSS9nU R                  (       d-  X;   a  [        S[        U5       35      eUR                  U5        U
(       a  Sn
OX-  n	U R                  X   X#SS9nXU-   U-   -  n	M     XS-   -  n	U	$ ! [         a    U R                  (       a   M  e f = f)Nz{}{Tr   zduplicate key F})_spacersr   r   r{   sortedrY   rU   r   r   rt   r,   r4   reprrV   )r   r   r   r   
indent_strend_stritem_sepkv_seprY   r5   	first_keynew_keysrZ   key_strval_strs                  r"   r   JSON5Encoder._encode_dict-  s*   "mmE2
&&3"">>#((*%D88:D*	5C++ct+D ,,&$~d3i[%ABBW%!	kk#(DkFG6!G++A' * 	
s]'  ==s   	DD0.D0c                    ^ ^^ U(       d  gT R                  T5      u  pET R                  U-   nSU-   UR                  UUU 4S jU 5       5      -   U-   S-   $ )Nz[][c              3   H   >#    U  H  nTR                  UTTS S9v   M     g7f)Fr   N)r   ).0rp   r   r   r   s     r"   	<genexpr>-JSON5Encoder._encode_array.<locals>.<genexpr>_  s%      EHrBeE:Ss   "])r   r   r   )r   r   r   r   r   r   r   s   ` ``   r"   r   JSON5Encoder._encode_arrayV  sl    "mmE2
&&3mm EH 
  	
r!   c                    U R                   b  SnU R                  (       a  Sn[        U R                   [        5      (       aL  U R                   S:  a1  SSU R                   -  U-  -   nUSSU R                   -  US-
  -  -   -  nO5SnUS-  n X24$ SU R                   U-  -   nUSU R                   US-
  -  -   -  nX24$ SnSnX24$ )Nr   r   r   r    r   )rx   r}   rA   r]   )r   r   r   r   s       r"   r   JSON5Encoder._spacersf  s    ;;"G##$++s++;;?!%dkk(9E(A!AJtcDKK&7519&EEEG!%JtOG "" "DKK%$77
4$++";;; "" JG""r!   rZ   c                     U(       a"  U R                  US   5      (       d
  US   S;  a  gUSS  H#  nU R                  U5      (       a  M  US;  d  M#    g   g)a"  Returns whether the string could be used as a legal
EcmaScript/JavaScript identifier.

There should normally be no reason to override this, unless
the definition of identifiers change in later versions of the
JSON5 spec and this implementation hasn't been updated to handle
the changes yet.r   )$r8   Fr   NT)_is_id_start_is_id_continue)r   rZ   r   s      r"   r   JSON5Encoder.is_identifierz  s[     $$SV,,Aj(ab'B''++*0D  r!   c                 4    [         R                  " U5      S;   $ )N)LuLlLiLtLmLoNlunicodedatacategoryr   r   s     r"   r   JSON5Encoder._is_id_start  s    ##B' ,
 
 	
r!   c                 4    [         R                  " U5      S;   $ )N)r  r  r  r  r  r  r  NdMnMcPcr  r  s     r"   r   JSON5Encoder._is_id_continue  s    ##B' ,
 
 	
r!   c                     [         c-  [        R                  " SSR                  / SQ5      -   S-   5      q [         R	                  U5      SL$ )zReturns whether the key is a reserved word.

There should normally be no need to override this, unless there
have been reserved words added in later versions of the JSON5
spec and this implementation has not yet been updated to handle
the changes yet.N(|)-breakcasecatchclassconstcontinuedebuggerrz   deletedoelseenumexportextendsr   finallyforfunctionif
implementsimportin
instanceof	interfaceletnewr   packageprivate	protectedpublicr0   staticsuperswitchthisthrowr   trytypeofvarvoidwhilewithyieldz)$)r   recompiler   match)r   rZ   s     r"   r   JSON5Encoder.is_reserved_word  sY     $
 !#

((.01d e24!j !&&s+477r!   )r,   rw   rv   r   ru   rx   r   r   r|   r~   ry   rt   r{   r}   )#r   r   r   r   r   r   boolr   r   r]   rE   r
   r   r   r   rz   r	   r   r   r   rP   r   r   r   r   r   rU   r   r   r   r   r   r   r   r    r   r!   r"   r   r   %  s    !#,00426  $%)",":":&' &' 	&'
 &' &' sCx)&' U38_-&' (C5#:./&' &' &' &' #&'  &'P$3 $3 $'='= '= 	'= '= 
'=Rc d x} 0)s )t ) )) )4 )C )$	>s 	>t 	> 	>8(c 8(
 8(s 8(t+S +S +@ C C 4' '3 's 's 'R
 
C 
 
 
 #c #eCHo #(  &	
s 	
t 	

# 
$ 
B8C B8D B8r!   c                 0    [        [        U 5       S35      e)Nz is not JSON5 serializable)r   r   )r   s    r"   r   r     s    
tCyk!;<
==r!   )#r   r   r>  typingr   r   r   r   r   r   r	   r
   r   r   r	  json5.parserr   r   Pattern__annotations__Enumr   rE   rB  r]   r9   r;   r3   rD   r^   r   r   r   r   r   r   r!   r"   <module>rI     s     	     +/ 8BJJ' .$ $J #@D260459 	!%!G
G smG 
	G
 (GCH$5#6#;<=G (C5#:./G #,-G XseSj12G G  (5c?+,c12G G G C=G  	!GZ #@D260459 	!%!;
; sm; 
	;
 (GCH$5#6#;<=; (C5#:./; #,-; XseSj12; ;  (5c?+,c12; ; ; C=;B #@D260459 	!%!g!
g! smg! 
	g!
 (GCH$5#6#;<=g! (C5#:./g! #,-g! XseSj12g! g!  (5c?+,c12g! g! g! C=g!TLB%*xc3h01367%*X *.(,,0.2 !%(66!/	/
/ 	/
 / / / 
$~&	'/ U38_%/ sCx)/ hucz*+/ / / / /  !/j *.(,,0.2 !%(66l>	l> l> 	l>
 l> l> 
$~&	'l> U38_%l> sCx)l> hucz*+l> l> l> l> l> l>^D8 D8N>c >r!   