diff --git a/apps/cic-eth/.coveragerc b/apps/cic-eth/.coveragerc
new file mode 100644
index 00000000..63f983d6
--- /dev/null
+++ b/apps/cic-eth/.coveragerc
@@ -0,0 +1,7 @@
+[report]
+omit =
+ .venv/*
+ scripts/*
+ cic_eth/db/migrations/*
+ cic_eth/sync/head.py
+ cic_eth/sync/mempool.py
diff --git a/apps/cic-eth/.envrc_dev_example b/apps/cic-eth/.envrc_dev_example
new file mode 100644
index 00000000..52999ec5
--- /dev/null
+++ b/apps/cic-eth/.envrc_dev_example
@@ -0,0 +1,12 @@
+set -a
+CICTEST_DEV_KEYS_PATH=
+CICTEST_DEV_SIGNER_PASSWORD=
+
+CICTEST_SIGNER_SECRET=deadbeef
+CICTEST_SIGNER_DATABASE=signer_test
+
+CICTEST_PIP_EXTRA_INDEX_HOST=
+CICTEST_PIP_EXTRA_INDEX_PORT=
+CICTEST_PIP_EXTRA_INDEX_PATH=
+CICTEST_PIP_EXTRA_INDEX_PROTO=
+set +a
diff --git a/apps/cic-eth/.envrc_example b/apps/cic-eth/.envrc_example
new file mode 100644
index 00000000..d803e0cc
--- /dev/null
+++ b/apps/cic-eth/.envrc_example
@@ -0,0 +1,21 @@
+set -a
+CICTEST_BANCOR_DIR=
+CICTEST_BANCOR_REGISTRY_ADDRESS=
+
+CICTEST_ETH_WS_PROVIDER='ws://localhost:8546'
+CICTEST_ETH_HTTP_PROVIDER='http://localhost:8545'
+CICTEST_ETH_PROVIDER=$CIC_ETH_HTTP_PROVIDER
+CICTEST_ETH_CHAIN_ID=8995
+CICTEST_ETH_GAS_PROVIDER_ADDRESS=
+
+CICTEST_DATABASE_ENGINE=postgresql
+CICTEST_DATABASE_DRIVER=psycopg2
+CICTEST_DATABASE_NAME=cic-eth-test
+CICTEST_DATABASE_USER=postgres
+CICTEST_DATABASE_PASSWORD=
+CICTEST_DATABASE_HOST=localhost
+CICTEST_DATABASE_PORT=5432
+
+CICTEST_CELERY_BROKER_URL=
+set +a
+. .envrc_dev_example
diff --git a/apps/cic-eth/.gitignore b/apps/cic-eth/.gitignore
new file mode 100644
index 00000000..dab8b439
--- /dev/null
+++ b/apps/cic-eth/.gitignore
@@ -0,0 +1,8 @@
+.envrc
+.envrc_dev
+.venv
+__pycache__
+*.pyc
+_build
+doc/**/*.png
+doc/**/html
diff --git a/apps/cic-eth/.gitlab-ci.yml b/apps/cic-eth/.gitlab-ci.yml
new file mode 100644
index 00000000..428002b8
--- /dev/null
+++ b/apps/cic-eth/.gitlab-ci.yml
@@ -0,0 +1,11 @@
+.contract-migration-changes-target:
+ rules:
+ - changes:
+ - $CONTEXT/*
+
+build-cic-eth:
+ extends:
+ - .contract-migration-changes-target
+ - .py-build
+ variables:
+ CONTEXT: apps/cic-eth
\ No newline at end of file
diff --git a/apps/cic-eth/CHANGELOG b/apps/cic-eth/CHANGELOG
new file mode 100644
index 00000000..266e4814
--- /dev/null
+++ b/apps/cic-eth/CHANGELOG
@@ -0,0 +1,114 @@
+- 0.10.0
+ * Move api to subpackage
+ * Add version identifier to package top level
+ * Add gas price proxy middleware
+ * Make initial queue send status inactive, introduce new status READYSEND for initial send attempt
+ * Add maintenance mode locks, and automatic account lock when node rejects to send a tx to network
+ * Add nonce repair tool
+ * Add tx resend admin api
+ * Add pure tcp and redis task api callbacks
+ * Add optional outgoing log status tracing
+ * Add lock lister and lock/unlock cli tool
+- 0.9.0
+ * Require chain spec parameter in api
+ * Pass chain spec between tasks
+- 0.8.9
+ * Change executable argument flag names for contract keys and chain spec
+ * Take over auxiliary code from cic-registry
+ * Use cic-bancor package for bancor related code
+- 0.8.8
+ * Implement transaction granularity for syncers
+- 0.8.7
+ * Add registration option on api account creation
+- 0.8.6
+ * Add persistent account role index
+- 0.8.5
+ * Add refill gas api call
+- 0.8.4
+ * Add settable abi dir to executables
+- 0.8.3
+ * Add faucet task, tests
+ * Add retry tx on incoming gas refill trigger
+ * Add transfer approval task, tests
+- 0.8.2
+ * Upgrade cic-registry
+ * Fix broken history syncer test
+- 0.8.1
+ * Upgrade dependencies
+- 0.8.0
+ * Rehabilitate tasker script
+ * Move tasker and manager scripts to console scripts setup entrypoints
+- 0.7.1
+ * Make tx hash optional in check-gas-and-send signature builder
+- 0.7.0
+ * Define callback tasks in API with qualified celery task strings
+- 0.6.4
+ * Add mock tx cache data generator
+ * Change sql tx cache value fields to bigint
+- 0.6.3
+ * Remove CIC-cache related code
+- 0.6.2
+ * Rename tx_number member of TxCache object to tx_index
+- 0.6.1
+ * Add postgres-only stored procedures for per-address balances and transactions queries
+- 0.6.0
+ * Configurable celery in worker script
+- 0.5.8
+ * Upgrade crypto-dev-signer (now uses SQLAlchemy)
+ * Use sql backend db for tests
+ * Use filesystem backend for celery tests
+- 0.5.7
+ * Remove environment variable dependencies in tests
+ * Update dependencies
+- 0.5.6
+ * Upgrade signer
+- 0.5.5
+ * Implement env-prefix switch in scripts
+- 0.5.4
+ * Add ipc path parameter to web3ext instantiation
+- 0.5.3
+ * Add alembic migration script customizable with confini
+- 0.5.2
+ * Upgrade crypto-dev-signer
+- 0.5.1
+ * Move tasker back to scripts
+- 0.5.0
+ * Create Api object, persists callback and queue across methods
+- 0.4.1
+ * Add docstrings
+ * Rehabilitate tests
+ * Correctly scope db sessions in tasks
+ * Add API for create account
+- 0.4.0
+ * Use config files instead of environment for cic-dev-tasker
+- 0.3.0
+ * Add queues
+- 0.2.0
+ * Add documentation
+ * Rename cic-dev-syncer to cic-dev-manager
+ * Rename cic-dev-track to cic-dev-tracker
+- 0.1.1
+ * Remove cic_eth.eth from packaging
+- 0.1.0
+ * Extract tx factory object controlling nonce and gasprice
+ * Fix bug from adapting method call to EthereumTester
+ * Package api for external use
+ * Add missing otx saves for transactions
+- 0.0.6
+ * Add missing "approve zero" for convert in monitor queue
+- 0.0.5
+ * Add customized eth_tester replacement for active web3 backend
+- 0.0.4
+ * Add api caller callback for completed tasks
+ * Add semaphore for web3 calls
+ * Add missing subtasks in bancor convert chain
+- 0.0.3
+ * Separate out registry and sempo to external packages
+- 0.0.2
+ * Add erc20 transfer task
+ * Add transaction queue tasker and database
+- 0.0.1
+ * Add registry
+ * Add bancor token lookup and convert tasks
+ * Add sempo token register tasks
+ * Add environment variable docs
diff --git a/apps/cic-eth/LICENSE.txt b/apps/cic-eth/LICENSE.txt
new file mode 100644
index 00000000..f288702d
--- /dev/null
+++ b/apps/cic-eth/LICENSE.txt
@@ -0,0 +1,674 @@
+ GNU GENERAL PUBLIC LICENSE
+ Version 3, 29 June 2007
+
+ Copyright (C) 2007 Free Software Foundation, Inc.
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The GNU General Public License is a free, copyleft license for
+software and other kinds of works.
+
+ The licenses for most software and other practical works are designed
+to take away your freedom to share and change the works. By contrast,
+the GNU General Public License is intended to guarantee your freedom to
+share and change all versions of a program--to make sure it remains free
+software for all its users. We, the Free Software Foundation, use the
+GNU General Public License for most of our software; it applies also to
+any other work released this way by its authors. You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+them if you wish), that you receive source code or can get it if you
+want it, that you can change the software or use pieces of it in new
+free programs, and that you know you can do these things.
+
+ To protect your rights, we need to prevent others from denying you
+these rights or asking you to surrender the rights. Therefore, you have
+certain responsibilities if you distribute copies of the software, or if
+you modify it: responsibilities to respect the freedom of others.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must pass on to the recipients the same
+freedoms that you received. You must make sure that they, too, receive
+or can get the source code. And you must show them these terms so they
+know their rights.
+
+ Developers that use the GNU GPL protect your rights with two steps:
+(1) assert copyright on the software, and (2) offer you this License
+giving you legal permission to copy, distribute and/or modify it.
+
+ For the developers' and authors' protection, the GPL clearly explains
+that there is no warranty for this free software. For both users' and
+authors' sake, the GPL requires that modified versions be marked as
+changed, so that their problems will not be attributed erroneously to
+authors of previous versions.
+
+ Some devices are designed to deny users access to install or run
+modified versions of the software inside them, although the manufacturer
+can do so. This is fundamentally incompatible with the aim of
+protecting users' freedom to change the software. The systematic
+pattern of such abuse occurs in the area of products for individuals to
+use, which is precisely where it is most unacceptable. Therefore, we
+have designed this version of the GPL to prohibit the practice for those
+products. If such problems arise substantially in other domains, we
+stand ready to extend this provision to those domains in future versions
+of the GPL, as needed to protect the freedom of users.
+
+ Finally, every program is threatened constantly by software patents.
+States should not allow patents to restrict development and use of
+software on general-purpose computers, but in those that do, we wish to
+avoid the special danger that patents applied to a free program could
+make it effectively proprietary. To prevent this, the GPL assures that
+patents cannot be used to render the program non-free.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ TERMS AND CONDITIONS
+
+ 0. Definitions.
+
+ "This License" refers to version 3 of the GNU General Public License.
+
+ "Copyright" also means copyright-like laws that apply to other kinds of
+works, such as semiconductor masks.
+
+ "The Program" refers to any copyrightable work licensed under this
+License. Each licensee is addressed as "you". "Licensees" and
+"recipients" may be individuals or organizations.
+
+ To "modify" a work means to copy from or adapt all or part of the work
+in a fashion requiring copyright permission, other than the making of an
+exact copy. The resulting work is called a "modified version" of the
+earlier work or a work "based on" the earlier work.
+
+ A "covered work" means either the unmodified Program or a work based
+on the Program.
+
+ To "propagate" a work means to do anything with it that, without
+permission, would make you directly or secondarily liable for
+infringement under applicable copyright law, except executing it on a
+computer or modifying a private copy. Propagation includes copying,
+distribution (with or without modification), making available to the
+public, and in some countries other activities as well.
+
+ To "convey" a work means any kind of propagation that enables other
+parties to make or receive copies. Mere interaction with a user through
+a computer network, with no transfer of a copy, is not conveying.
+
+ An interactive user interface displays "Appropriate Legal Notices"
+to the extent that it includes a convenient and prominently visible
+feature that (1) displays an appropriate copyright notice, and (2)
+tells the user that there is no warranty for the work (except to the
+extent that warranties are provided), that licensees may convey the
+work under this License, and how to view a copy of this License. If
+the interface presents a list of user commands or options, such as a
+menu, a prominent item in the list meets this criterion.
+
+ 1. Source Code.
+
+ The "source code" for a work means the preferred form of the work
+for making modifications to it. "Object code" means any non-source
+form of a work.
+
+ A "Standard Interface" means an interface that either is an official
+standard defined by a recognized standards body, or, in the case of
+interfaces specified for a particular programming language, one that
+is widely used among developers working in that language.
+
+ The "System Libraries" of an executable work include anything, other
+than the work as a whole, that (a) is included in the normal form of
+packaging a Major Component, but which is not part of that Major
+Component, and (b) serves only to enable use of the work with that
+Major Component, or to implement a Standard Interface for which an
+implementation is available to the public in source code form. A
+"Major Component", in this context, means a major essential component
+(kernel, window system, and so on) of the specific operating system
+(if any) on which the executable work runs, or a compiler used to
+produce the work, or an object code interpreter used to run it.
+
+ The "Corresponding Source" for a work in object code form means all
+the source code needed to generate, install, and (for an executable
+work) run the object code and to modify the work, including scripts to
+control those activities. However, it does not include the work's
+System Libraries, or general-purpose tools or generally available free
+programs which are used unmodified in performing those activities but
+which are not part of the work. For example, Corresponding Source
+includes interface definition files associated with source files for
+the work, and the source code for shared libraries and dynamically
+linked subprograms that the work is specifically designed to require,
+such as by intimate data communication or control flow between those
+subprograms and other parts of the work.
+
+ The Corresponding Source need not include anything that users
+can regenerate automatically from other parts of the Corresponding
+Source.
+
+ The Corresponding Source for a work in source code form is that
+same work.
+
+ 2. Basic Permissions.
+
+ All rights granted under this License are granted for the term of
+copyright on the Program, and are irrevocable provided the stated
+conditions are met. This License explicitly affirms your unlimited
+permission to run the unmodified Program. The output from running a
+covered work is covered by this License only if the output, given its
+content, constitutes a covered work. This License acknowledges your
+rights of fair use or other equivalent, as provided by copyright law.
+
+ You may make, run and propagate covered works that you do not
+convey, without conditions so long as your license otherwise remains
+in force. You may convey covered works to others for the sole purpose
+of having them make modifications exclusively for you, or provide you
+with facilities for running those works, provided that you comply with
+the terms of this License in conveying all material for which you do
+not control copyright. Those thus making or running the covered works
+for you must do so exclusively on your behalf, under your direction
+and control, on terms that prohibit them from making any copies of
+your copyrighted material outside their relationship with you.
+
+ Conveying under any other circumstances is permitted solely under
+the conditions stated below. Sublicensing is not allowed; section 10
+makes it unnecessary.
+
+ 3. Protecting Users' Legal Rights From Anti-Circumvention Law.
+
+ No covered work shall be deemed part of an effective technological
+measure under any applicable law fulfilling obligations under article
+11 of the WIPO copyright treaty adopted on 20 December 1996, or
+similar laws prohibiting or restricting circumvention of such
+measures.
+
+ When you convey a covered work, you waive any legal power to forbid
+circumvention of technological measures to the extent such circumvention
+is effected by exercising rights under this License with respect to
+the covered work, and you disclaim any intention to limit operation or
+modification of the work as a means of enforcing, against the work's
+users, your or third parties' legal rights to forbid circumvention of
+technological measures.
+
+ 4. Conveying Verbatim Copies.
+
+ You may convey verbatim copies of the Program's source code as you
+receive it, in any medium, provided that you conspicuously and
+appropriately publish on each copy an appropriate copyright notice;
+keep intact all notices stating that this License and any
+non-permissive terms added in accord with section 7 apply to the code;
+keep intact all notices of the absence of any warranty; and give all
+recipients a copy of this License along with the Program.
+
+ You may charge any price or no price for each copy that you convey,
+and you may offer support or warranty protection for a fee.
+
+ 5. Conveying Modified Source Versions.
+
+ You may convey a work based on the Program, or the modifications to
+produce it from the Program, in the form of source code under the
+terms of section 4, provided that you also meet all of these conditions:
+
+ a) The work must carry prominent notices stating that you modified
+ it, and giving a relevant date.
+
+ b) The work must carry prominent notices stating that it is
+ released under this License and any conditions added under section
+ 7. This requirement modifies the requirement in section 4 to
+ "keep intact all notices".
+
+ c) You must license the entire work, as a whole, under this
+ License to anyone who comes into possession of a copy. This
+ License will therefore apply, along with any applicable section 7
+ additional terms, to the whole of the work, and all its parts,
+ regardless of how they are packaged. This License gives no
+ permission to license the work in any other way, but it does not
+ invalidate such permission if you have separately received it.
+
+ d) If the work has interactive user interfaces, each must display
+ Appropriate Legal Notices; however, if the Program has interactive
+ interfaces that do not display Appropriate Legal Notices, your
+ work need not make them do so.
+
+ A compilation of a covered work with other separate and independent
+works, which are not by their nature extensions of the covered work,
+and which are not combined with it such as to form a larger program,
+in or on a volume of a storage or distribution medium, is called an
+"aggregate" if the compilation and its resulting copyright are not
+used to limit the access or legal rights of the compilation's users
+beyond what the individual works permit. Inclusion of a covered work
+in an aggregate does not cause this License to apply to the other
+parts of the aggregate.
+
+ 6. Conveying Non-Source Forms.
+
+ You may convey a covered work in object code form under the terms
+of sections 4 and 5, provided that you also convey the
+machine-readable Corresponding Source under the terms of this License,
+in one of these ways:
+
+ a) Convey the object code in, or embodied in, a physical product
+ (including a physical distribution medium), accompanied by the
+ Corresponding Source fixed on a durable physical medium
+ customarily used for software interchange.
+
+ b) Convey the object code in, or embodied in, a physical product
+ (including a physical distribution medium), accompanied by a
+ written offer, valid for at least three years and valid for as
+ long as you offer spare parts or customer support for that product
+ model, to give anyone who possesses the object code either (1) a
+ copy of the Corresponding Source for all the software in the
+ product that is covered by this License, on a durable physical
+ medium customarily used for software interchange, for a price no
+ more than your reasonable cost of physically performing this
+ conveying of source, or (2) access to copy the
+ Corresponding Source from a network server at no charge.
+
+ c) Convey individual copies of the object code with a copy of the
+ written offer to provide the Corresponding Source. This
+ alternative is allowed only occasionally and noncommercially, and
+ only if you received the object code with such an offer, in accord
+ with subsection 6b.
+
+ d) Convey the object code by offering access from a designated
+ place (gratis or for a charge), and offer equivalent access to the
+ Corresponding Source in the same way through the same place at no
+ further charge. You need not require recipients to copy the
+ Corresponding Source along with the object code. If the place to
+ copy the object code is a network server, the Corresponding Source
+ may be on a different server (operated by you or a third party)
+ that supports equivalent copying facilities, provided you maintain
+ clear directions next to the object code saying where to find the
+ Corresponding Source. Regardless of what server hosts the
+ Corresponding Source, you remain obligated to ensure that it is
+ available for as long as needed to satisfy these requirements.
+
+ e) Convey the object code using peer-to-peer transmission, provided
+ you inform other peers where the object code and Corresponding
+ Source of the work are being offered to the general public at no
+ charge under subsection 6d.
+
+ A separable portion of the object code, whose source code is excluded
+from the Corresponding Source as a System Library, need not be
+included in conveying the object code work.
+
+ A "User Product" is either (1) a "consumer product", which means any
+tangible personal property which is normally used for personal, family,
+or household purposes, or (2) anything designed or sold for incorporation
+into a dwelling. In determining whether a product is a consumer product,
+doubtful cases shall be resolved in favor of coverage. For a particular
+product received by a particular user, "normally used" refers to a
+typical or common use of that class of product, regardless of the status
+of the particular user or of the way in which the particular user
+actually uses, or expects or is expected to use, the product. A product
+is a consumer product regardless of whether the product has substantial
+commercial, industrial or non-consumer uses, unless such uses represent
+the only significant mode of use of the product.
+
+ "Installation Information" for a User Product means any methods,
+procedures, authorization keys, or other information required to install
+and execute modified versions of a covered work in that User Product from
+a modified version of its Corresponding Source. The information must
+suffice to ensure that the continued functioning of the modified object
+code is in no case prevented or interfered with solely because
+modification has been made.
+
+ If you convey an object code work under this section in, or with, or
+specifically for use in, a User Product, and the conveying occurs as
+part of a transaction in which the right of possession and use of the
+User Product is transferred to the recipient in perpetuity or for a
+fixed term (regardless of how the transaction is characterized), the
+Corresponding Source conveyed under this section must be accompanied
+by the Installation Information. But this requirement does not apply
+if neither you nor any third party retains the ability to install
+modified object code on the User Product (for example, the work has
+been installed in ROM).
+
+ The requirement to provide Installation Information does not include a
+requirement to continue to provide support service, warranty, or updates
+for a work that has been modified or installed by the recipient, or for
+the User Product in which it has been modified or installed. Access to a
+network may be denied when the modification itself materially and
+adversely affects the operation of the network or violates the rules and
+protocols for communication across the network.
+
+ Corresponding Source conveyed, and Installation Information provided,
+in accord with this section must be in a format that is publicly
+documented (and with an implementation available to the public in
+source code form), and must require no special password or key for
+unpacking, reading or copying.
+
+ 7. Additional Terms.
+
+ "Additional permissions" are terms that supplement the terms of this
+License by making exceptions from one or more of its conditions.
+Additional permissions that are applicable to the entire Program shall
+be treated as though they were included in this License, to the extent
+that they are valid under applicable law. If additional permissions
+apply only to part of the Program, that part may be used separately
+under those permissions, but the entire Program remains governed by
+this License without regard to the additional permissions.
+
+ When you convey a copy of a covered work, you may at your option
+remove any additional permissions from that copy, or from any part of
+it. (Additional permissions may be written to require their own
+removal in certain cases when you modify the work.) You may place
+additional permissions on material, added by you to a covered work,
+for which you have or can give appropriate copyright permission.
+
+ Notwithstanding any other provision of this License, for material you
+add to a covered work, you may (if authorized by the copyright holders of
+that material) supplement the terms of this License with terms:
+
+ a) Disclaiming warranty or limiting liability differently from the
+ terms of sections 15 and 16 of this License; or
+
+ b) Requiring preservation of specified reasonable legal notices or
+ author attributions in that material or in the Appropriate Legal
+ Notices displayed by works containing it; or
+
+ c) Prohibiting misrepresentation of the origin of that material, or
+ requiring that modified versions of such material be marked in
+ reasonable ways as different from the original version; or
+
+ d) Limiting the use for publicity purposes of names of licensors or
+ authors of the material; or
+
+ e) Declining to grant rights under trademark law for use of some
+ trade names, trademarks, or service marks; or
+
+ f) Requiring indemnification of licensors and authors of that
+ material by anyone who conveys the material (or modified versions of
+ it) with contractual assumptions of liability to the recipient, for
+ any liability that these contractual assumptions directly impose on
+ those licensors and authors.
+
+ All other non-permissive additional terms are considered "further
+restrictions" within the meaning of section 10. If the Program as you
+received it, or any part of it, contains a notice stating that it is
+governed by this License along with a term that is a further
+restriction, you may remove that term. If a license document contains
+a further restriction but permits relicensing or conveying under this
+License, you may add to a covered work material governed by the terms
+of that license document, provided that the further restriction does
+not survive such relicensing or conveying.
+
+ If you add terms to a covered work in accord with this section, you
+must place, in the relevant source files, a statement of the
+additional terms that apply to those files, or a notice indicating
+where to find the applicable terms.
+
+ Additional terms, permissive or non-permissive, may be stated in the
+form of a separately written license, or stated as exceptions;
+the above requirements apply either way.
+
+ 8. Termination.
+
+ You may not propagate or modify a covered work except as expressly
+provided under this License. Any attempt otherwise to propagate or
+modify it is void, and will automatically terminate your rights under
+this License (including any patent licenses granted under the third
+paragraph of section 11).
+
+ However, if you cease all violation of this License, then your
+license from a particular copyright holder is reinstated (a)
+provisionally, unless and until the copyright holder explicitly and
+finally terminates your license, and (b) permanently, if the copyright
+holder fails to notify you of the violation by some reasonable means
+prior to 60 days after the cessation.
+
+ Moreover, your license from a particular copyright holder is
+reinstated permanently if the copyright holder notifies you of the
+violation by some reasonable means, this is the first time you have
+received notice of violation of this License (for any work) from that
+copyright holder, and you cure the violation prior to 30 days after
+your receipt of the notice.
+
+ Termination of your rights under this section does not terminate the
+licenses of parties who have received copies or rights from you under
+this License. If your rights have been terminated and not permanently
+reinstated, you do not qualify to receive new licenses for the same
+material under section 10.
+
+ 9. Acceptance Not Required for Having Copies.
+
+ You are not required to accept this License in order to receive or
+run a copy of the Program. Ancillary propagation of a covered work
+occurring solely as a consequence of using peer-to-peer transmission
+to receive a copy likewise does not require acceptance. However,
+nothing other than this License grants you permission to propagate or
+modify any covered work. These actions infringe copyright if you do
+not accept this License. Therefore, by modifying or propagating a
+covered work, you indicate your acceptance of this License to do so.
+
+ 10. Automatic Licensing of Downstream Recipients.
+
+ Each time you convey a covered work, the recipient automatically
+receives a license from the original licensors, to run, modify and
+propagate that work, subject to this License. You are not responsible
+for enforcing compliance by third parties with this License.
+
+ An "entity transaction" is a transaction transferring control of an
+organization, or substantially all assets of one, or subdividing an
+organization, or merging organizations. If propagation of a covered
+work results from an entity transaction, each party to that
+transaction who receives a copy of the work also receives whatever
+licenses to the work the party's predecessor in interest had or could
+give under the previous paragraph, plus a right to possession of the
+Corresponding Source of the work from the predecessor in interest, if
+the predecessor has it or can get it with reasonable efforts.
+
+ You may not impose any further restrictions on the exercise of the
+rights granted or affirmed under this License. For example, you may
+not impose a license fee, royalty, or other charge for exercise of
+rights granted under this License, and you may not initiate litigation
+(including a cross-claim or counterclaim in a lawsuit) alleging that
+any patent claim is infringed by making, using, selling, offering for
+sale, or importing the Program or any portion of it.
+
+ 11. Patents.
+
+ A "contributor" is a copyright holder who authorizes use under this
+License of the Program or a work on which the Program is based. The
+work thus licensed is called the contributor's "contributor version".
+
+ A contributor's "essential patent claims" are all patent claims
+owned or controlled by the contributor, whether already acquired or
+hereafter acquired, that would be infringed by some manner, permitted
+by this License, of making, using, or selling its contributor version,
+but do not include claims that would be infringed only as a
+consequence of further modification of the contributor version. For
+purposes of this definition, "control" includes the right to grant
+patent sublicenses in a manner consistent with the requirements of
+this License.
+
+ Each contributor grants you a non-exclusive, worldwide, royalty-free
+patent license under the contributor's essential patent claims, to
+make, use, sell, offer for sale, import and otherwise run, modify and
+propagate the contents of its contributor version.
+
+ In the following three paragraphs, a "patent license" is any express
+agreement or commitment, however denominated, not to enforce a patent
+(such as an express permission to practice a patent or covenant not to
+sue for patent infringement). To "grant" such a patent license to a
+party means to make such an agreement or commitment not to enforce a
+patent against the party.
+
+ If you convey a covered work, knowingly relying on a patent license,
+and the Corresponding Source of the work is not available for anyone
+to copy, free of charge and under the terms of this License, through a
+publicly available network server or other readily accessible means,
+then you must either (1) cause the Corresponding Source to be so
+available, or (2) arrange to deprive yourself of the benefit of the
+patent license for this particular work, or (3) arrange, in a manner
+consistent with the requirements of this License, to extend the patent
+license to downstream recipients. "Knowingly relying" means you have
+actual knowledge that, but for the patent license, your conveying the
+covered work in a country, or your recipient's use of the covered work
+in a country, would infringe one or more identifiable patents in that
+country that you have reason to believe are valid.
+
+ If, pursuant to or in connection with a single transaction or
+arrangement, you convey, or propagate by procuring conveyance of, a
+covered work, and grant a patent license to some of the parties
+receiving the covered work authorizing them to use, propagate, modify
+or convey a specific copy of the covered work, then the patent license
+you grant is automatically extended to all recipients of the covered
+work and works based on it.
+
+ A patent license is "discriminatory" if it does not include within
+the scope of its coverage, prohibits the exercise of, or is
+conditioned on the non-exercise of one or more of the rights that are
+specifically granted under this License. You may not convey a covered
+work if you are a party to an arrangement with a third party that is
+in the business of distributing software, under which you make payment
+to the third party based on the extent of your activity of conveying
+the work, and under which the third party grants, to any of the
+parties who would receive the covered work from you, a discriminatory
+patent license (a) in connection with copies of the covered work
+conveyed by you (or copies made from those copies), or (b) primarily
+for and in connection with specific products or compilations that
+contain the covered work, unless you entered into that arrangement,
+or that patent license was granted, prior to 28 March 2007.
+
+ Nothing in this License shall be construed as excluding or limiting
+any implied license or other defenses to infringement that may
+otherwise be available to you under applicable patent law.
+
+ 12. No Surrender of Others' Freedom.
+
+ If conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot convey a
+covered work so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you may
+not convey it at all. For example, if you agree to terms that obligate you
+to collect a royalty for further conveying from those to whom you convey
+the Program, the only way you could satisfy both those terms and this
+License would be to refrain entirely from conveying the Program.
+
+ 13. Use with the GNU Affero General Public License.
+
+ Notwithstanding any other provision of this License, you have
+permission to link or combine any covered work with a work licensed
+under version 3 of the GNU Affero General Public License into a single
+combined work, and to convey the resulting work. The terms of this
+License will continue to apply to the part which is the covered work,
+but the special requirements of the GNU Affero General Public License,
+section 13, concerning interaction through a network will apply to the
+combination as such.
+
+ 14. Revised Versions of this License.
+
+ The Free Software Foundation may publish revised and/or new versions of
+the GNU General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+ Each version is given a distinguishing version number. If the
+Program specifies that a certain numbered version of the GNU General
+Public License "or any later version" applies to it, you have the
+option of following the terms and conditions either of that numbered
+version or of any later version published by the Free Software
+Foundation. If the Program does not specify a version number of the
+GNU General Public License, you may choose any version ever published
+by the Free Software Foundation.
+
+ If the Program specifies that a proxy can decide which future
+versions of the GNU General Public License can be used, that proxy's
+public statement of acceptance of a version permanently authorizes you
+to choose that version for the Program.
+
+ Later license versions may give you additional or different
+permissions. However, no additional obligations are imposed on any
+author or copyright holder as a result of your choosing to follow a
+later version.
+
+ 15. Disclaimer of Warranty.
+
+ THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
+APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
+HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
+OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
+THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
+IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
+ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
+
+ 16. Limitation of Liability.
+
+ IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
+THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
+GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
+USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
+DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
+PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
+EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
+SUCH DAMAGES.
+
+ 17. Interpretation of Sections 15 and 16.
+
+ If the disclaimer of warranty and limitation of liability provided
+above cannot be given local legal effect according to their terms,
+reviewing courts shall apply local law that most closely approximates
+an absolute waiver of all civil liability in connection with the
+Program, unless a warranty or assumption of liability accompanies a
+copy of the Program in return for a fee.
+
+ END OF TERMS AND CONDITIONS
+
+ How to Apply These Terms to Your New Programs
+
+ If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+ To do so, attach the following notices to the program. It is safest
+to attach them to the start of each source file to most effectively
+state the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+
+ Copyright (C)
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see .
+
+Also add information on how to contact you by electronic and paper mail.
+
+ If the program does terminal interaction, make it output a short
+notice like this when it starts in an interactive mode:
+
+ Copyright (C)
+ This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+ This is free software, and you are welcome to redistribute it
+ under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License. Of course, your program's commands
+might be different; for a GUI interface, you would use an "about box".
+
+ You should also get your employer (if you work as a programmer) or school,
+if any, to sign a "copyright disclaimer" for the program, if necessary.
+For more information on this, and how to apply and follow the GNU GPL, see
+.
+
+ The GNU General Public License does not permit incorporating your program
+into proprietary programs. If your program is a subroutine library, you
+may consider it more useful to permit linking proprietary applications with
+the library. If this is what you want to do, use the GNU Lesser General
+Public License instead of this License. But first, please read
+.
diff --git a/apps/cic-eth/cic_eth/__init__.py b/apps/cic-eth/cic_eth/__init__.py
new file mode 100644
index 00000000..adc978e9
--- /dev/null
+++ b/apps/cic-eth/cic_eth/__init__.py
@@ -0,0 +1,10 @@
+"""Celery tasks API for CIC EVM and web3 JSON-RPC interactions
+
+.. moduleauthor: Louis Holbrook
+
+"""
+
+from .version import (
+ version,
+ version_string,
+ )
diff --git a/apps/cic-eth/cic_eth/admin/ctrl.py b/apps/cic-eth/cic_eth/admin/ctrl.py
new file mode 100644
index 00000000..6b28d86d
--- /dev/null
+++ b/apps/cic-eth/cic_eth/admin/ctrl.py
@@ -0,0 +1,125 @@
+# standard imports
+import datetime
+import logging
+
+# third-party imports
+import celery
+from cic_registry import zero_address
+
+# local imports
+from cic_eth.db.enum import LockEnum
+from cic_eth.db.models.lock import Lock
+from cic_eth.error import LockedError
+
+celery_app = celery.current_app
+logg = logging.getLogger()
+
+@celery_app.task()
+def lock(chained_input, chain_str, address=zero_address, flags=LockEnum.ALL, tx_hash=None):
+ """Task wrapper to set arbitrary locks
+
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :param flags: Flags to set
+ :type flags: number
+ :param address: Ethereum address
+ :type address: str, 0x-hex
+ :returns: New lock state for address
+ :rtype: number
+ """
+ r = Lock.set(chain_str, flags, address=address, tx_hash=tx_hash)
+ logg.debug('Locked {} for {}, flag now {}'.format(flags, address, r))
+ return chained_input
+
+
+@celery_app.task()
+def unlock(chained_input, chain_str, address=zero_address, flags=LockEnum.ALL):
+ """Task wrapper to reset arbitrary locks
+
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :param flags: Flags to set
+ :type flags: number
+ :param address: Ethereum address
+ :type address: str, 0x-hex
+ :returns: New lock state for address
+ :rtype: number
+ """
+ r = Lock.reset(chain_str, flags, address=address)
+ logg.debug('Unlocked {} for {}, flag now {}'.format(flags, address, r))
+ return chained_input
+
+
+@celery_app.task()
+def lock_send(chained_input, chain_str, address=zero_address, tx_hash=None):
+ """Task wrapper to set send lock
+
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :param address: Ethereum address
+ :type address: str, 0x-hex
+ :returns: New lock state for address
+ :rtype: number
+ """
+ r = Lock.set(chain_str, LockEnum.SEND, address=address, tx_hash=tx_hash)
+ logg.debug('Send locked for {}, flag now {}'.format(address, r))
+ return chained_input
+
+
+@celery_app.task()
+def unlock_send(chained_input, chain_str, address=zero_address):
+ """Task wrapper to reset send lock
+
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :param address: Ethereum address
+ :type address: str, 0x-hex
+ :returns: New lock state for address
+ :rtype: number
+ """
+ r = Lock.reset(chain_str, LockEnum.SEND, address=address)
+ logg.debug('Send unlocked for {}, flag now {}'.format(address, r))
+ return chained_input
+
+
+@celery_app.task()
+def lock_queue(chained_input, chain_str, address=zero_address, tx_hash=None):
+ """Task wrapper to set queue direct lock
+
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :param address: Ethereum address
+ :type address: str, 0x-hex
+ :returns: New lock state for address
+ :rtype: number
+ """
+ r = Lock.set(chain_str, LockEnum.QUEUE, address=address, tx_hash=tx_hash)
+ logg.debug('Queue direct locked for {}, flag now {}'.format(address, r))
+ return chained_input
+
+
+@celery_app.task()
+def unlock_queue(chained_input, chain_str, address=zero_address):
+ """Task wrapper to reset queue direct lock
+
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :param address: Ethereum address
+ :type address: str, 0x-hex
+ :returns: New lock state for address
+ :rtype: number
+ """
+ r = Lock.reset(chain_str, LockEnum.QUEUE, address=address)
+ logg.debug('Queue direct unlocked for {}, flag now {}'.format(address, r))
+ return chained_input
+
+
+@celery_app.task()
+def check_lock(chained_input, chain_str, lock_flags, address=None):
+ r = Lock.check(chain_str, lock_flags, address=zero_address)
+ if address != None:
+ r |= Lock.check(chain_str, lock_flags, address=address)
+ if r > 0:
+ logg.debug('lock check {} has match {} for {}'.format(lock_flags, r, address))
+ raise LockedError(r)
+ return chained_input
diff --git a/apps/cic-eth/cic_eth/admin/debug.py b/apps/cic-eth/cic_eth/admin/debug.py
new file mode 100644
index 00000000..575be543
--- /dev/null
+++ b/apps/cic-eth/cic_eth/admin/debug.py
@@ -0,0 +1,12 @@
+import datetime
+
+import celery
+
+celery_app = celery.current_app
+
+
+@celery_app.task()
+def out_tmp(tag, txt):
+ f = open('/tmp/err.{}.txt'.format(tag), "w")
+ f.write(txt)
+ f.close()
diff --git a/apps/cic-eth/cic_eth/admin/nonce.py b/apps/cic-eth/cic_eth/admin/nonce.py
new file mode 100644
index 00000000..c475f7b3
--- /dev/null
+++ b/apps/cic-eth/cic_eth/admin/nonce.py
@@ -0,0 +1,128 @@
+# standard imports
+import logging
+
+# third-party imports
+import celery
+from cic_registry.chain import ChainSpec
+
+# local imports
+from cic_eth.db.models.base import SessionBase
+from cic_eth.db.models.otx import Otx
+from cic_eth.db.models.tx import TxCache
+from cic_eth.db.models.nonce import Nonce
+from cic_eth.admin.ctrl import lock_send
+from cic_eth.admin.ctrl import unlock_send
+from cic_eth.admin.ctrl import lock_queue
+from cic_eth.admin.ctrl import unlock_queue
+from cic_eth.queue.tx import get_tx
+from cic_eth.queue.tx import set_cancel
+from cic_eth.queue.tx import create as queue_create
+from cic_eth.eth.util import unpack_signed_raw_tx
+from cic_eth.eth.task import sign_tx
+from cic_eth.eth.task import create_check_gas_and_send_task
+
+celery_app = celery.current_app
+logg = logging.getLogger()
+
+
+@celery_app.task(bind=True)
+def shift_nonce(self, chain_str, tx_hash_orig_hex, delta=1):
+ """Shift all transactions with nonces higher than the offset by the provided position delta.
+
+ Transactions who are replaced by transactions that move nonces will be marked as OVERRIDDEN.
+
+ :param chainstr: Chain specification string representation
+ :type chainstr: str
+ :param tx_hash_orig_hex: Transaction hash to resolve to sender and nonce to use as shift offset
+ :type tx_hash_orig_hex: str, 0x-hex
+ :param delta: Amount
+ """
+ queue = None
+ try:
+ queue = self.request.delivery_info.get('routing_key')
+ except AttributeError:
+ pass
+
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ tx_brief = get_tx(tx_hash_orig_hex)
+ tx_raw = bytes.fromhex(tx_brief['signed_tx'][2:])
+ tx = unpack_signed_raw_tx(tx_raw, chain_spec.chain_id())
+ nonce = tx_brief['nonce']
+ address = tx['from']
+
+ logg.debug('shifting nonce {} position(s) for address {}, offset {}'.format(delta, address, nonce))
+
+ lock_queue(None, chain_str, address)
+ lock_send(None, chain_str, address)
+
+ session = SessionBase.create_session()
+ q = session.query(Otx)
+ q = q.join(TxCache)
+ q = q.filter(TxCache.sender==address)
+ q = q.filter(Otx.nonce>=nonce+delta)
+ q = q.order_by(Otx.nonce.asc())
+ otxs = q.all()
+
+ tx_hashes = []
+ txs = []
+ for otx in otxs:
+ tx_raw = bytes.fromhex(otx.signed_tx[2:])
+ tx_new = unpack_signed_raw_tx(tx_raw, chain_spec.chain_id())
+
+ tx_previous_hash_hex = tx_new['hash']
+ tx_previous_nonce = tx_new['nonce']
+
+ del(tx_new['hash'])
+ del(tx_new['hash_unsigned'])
+ tx_new['nonce'] -= delta
+
+ (tx_hash_hex, tx_signed_raw_hex) = sign_tx(tx_new, chain_str)
+ logg.debug('tx {} -> {} nonce {} -> {}'.format(tx_previous_hash_hex, tx_hash_hex, tx_previous_nonce, tx_new['nonce']))
+
+ otx = Otx(
+ nonce=tx_new['nonce'],
+ address=tx_new['from'],
+ tx_hash=tx_hash_hex,
+ signed_tx=tx_signed_raw_hex,
+ )
+ session.add(otx)
+ session.commit()
+
+ # TODO: cancel all first, then replace. Otherwise we risk two non-locked states for two different nonces.
+ set_cancel(tx_previous_hash_hex, True)
+
+ TxCache.clone(tx_previous_hash_hex, tx_hash_hex)
+
+ tx_hashes.append(tx_hash_hex)
+ txs.append(tx_signed_raw_hex)
+
+ session.close()
+
+ s = create_check_gas_and_send_task(
+ txs,
+ chain_str,
+ tx_new['from'],
+ tx_new['gas'],
+ tx_hashes,
+ queue,
+ )
+
+ s_unlock_send = celery.signature(
+ 'cic_eth.admin.ctrl.unlock_send',
+ [
+ chain_str,
+ tx_new['from'],
+ ],
+ queue=queue,
+ )
+ s_unlock_direct = celery.signature(
+ 'cic_eth.admin.ctrl.unlock_queue',
+ [
+ chain_str,
+ tx_new['from'],
+ ],
+ queue=queue,
+ )
+ s_unlocks = celery.group(s_unlock_send, s_unlock_direct)
+ s.link(s_unlocks)
+ s.apply_async()
diff --git a/apps/cic-eth/cic_eth/api/__init__.py b/apps/cic-eth/cic_eth/api/__init__.py
new file mode 100644
index 00000000..ce747f4f
--- /dev/null
+++ b/apps/cic-eth/cic_eth/api/__init__.py
@@ -0,0 +1,8 @@
+"""Celery tasks API for CIC EVM and web3 JSON-RPC interactions
+
+.. moduleauthor: Louis Holbrook
+
+"""
+
+from .api_task import Api
+from .api_admin import AdminApi
diff --git a/apps/cic-eth/cic_eth/api/api_admin.py b/apps/cic-eth/cic_eth/api/api_admin.py
new file mode 100644
index 00000000..aec9cd47
--- /dev/null
+++ b/apps/cic-eth/cic_eth/api/api_admin.py
@@ -0,0 +1,445 @@
+# standard imports
+import logging
+
+# third-party imports
+import celery
+import web3
+from cic_registry import zero_address
+from cic_registry import zero_content
+from cic_registry import CICRegistry
+from crypto_dev_signer.eth.web3ext import Web3 as Web3Ext
+from cic_registry.error import UnknownContractError
+
+# local imports
+from cic_eth.db.models.base import SessionBase
+from cic_eth.db.models.role import AccountRole
+from cic_eth.db.models.otx import Otx
+from cic_eth.db.models.tx import TxCache
+from cic_eth.db.models.nonce import Nonce
+from cic_eth.db.enum import StatusEnum
+from cic_eth.error import InitializationError
+from cic_eth.db.error import TxStateChangeError
+from cic_eth.eth.rpc import RpcClient
+from cic_eth.queue.tx import get_tx
+from cic_eth.eth.util import unpack_signed_raw_tx
+
+app = celery.current_app
+
+#logg = logging.getLogger(__file__)
+logg = logging.getLogger()
+
+
+class AdminApi:
+ """Provides an interface to view and manipulate existing transaction tasks and system runtime settings.
+
+ :param rpc_client: Rpc client to use for blockchain connections.
+ :type rpc_client: cic_eth.eth.rpc.RpcClient
+ :param queue: Name of worker queue to submit tasks to
+ :type queue: str
+ """
+ def __init__(self, rpc_client, queue='cic-eth'):
+ self.rpc_client = rpc_client
+ self.w3 = rpc_client.w3
+ self.queue = queue
+
+
+ def unlock(self, chain_spec, address, flags=None):
+ s_unlock = celery.signature(
+ 'cic_eth.admin.ctrl.unlock',
+ [
+ str(chain_spec),
+ flags,
+ address,
+ ],
+ queue=self.queue,
+ )
+ return s_unlock.apply_async()
+
+
+ def lock(self, chain_spec, address, flags=None):
+ s_lock = celery.signature(
+ 'cic_eth.admin.ctrl.lock',
+ [
+ str(chain_spec),
+ flags,
+ address,
+ ],
+ queue=self.queue,
+ )
+ return s_lock.apply_async()
+
+
+ def get_lock(self):
+ s_lock = celery.signature(
+ 'cic_eth.queue.tx.get_lock',
+ [],
+ queue=self.queue,
+ )
+ return s_lock.apply_async().get()
+
+
+ def tag_account(self, tag, address_hex):
+ """Persistently associate an address with a plaintext tag.
+
+ Some tags are known by the system and is used to resolve addresses to use for certain transactions.
+
+ :param tag: Address tag
+ :type tag: str
+ :param address_hex: Ethereum address to tag
+ :type address_hex: str, 0x-hex
+ :raises ValueError: Invalid checksum address
+ """
+ if not web3.Web3.isChecksumAddress(address_hex):
+ raise ValueError('invalid address')
+ session = SessionBase.create_session()
+ role = AccountRole.set(tag, address_hex)
+ session.add(role)
+ session.commit()
+ session.close()
+
+
+ def resend(self, tx_hash_hex, chain_str, in_place=True, unlock=False):
+ logg.debug('resend {}'.format(tx_hash_hex))
+ s_get_tx_cache = celery.signature(
+ 'cic_eth.queue.tx.get_tx_cache',
+ [
+ tx_hash_hex,
+ ],
+ queue=self.queue,
+ )
+
+ # TODO: This check should most likely be in resend task itself
+ tx_dict = s_get_tx_cache.apply_async().get()
+ if tx_dict['status'] in [StatusEnum.REVERTED, StatusEnum.SUCCESS, StatusEnum.CANCELLED, StatusEnum.OBSOLETED]:
+ raise TxStateChangeError('Cannot resend mined or obsoleted transaction'.format(txold_hash_hex))
+
+ s = None
+ if in_place:
+ s = celery.signature(
+ 'cic_eth.eth.tx.resend_with_higher_gas',
+ [
+ tx_hash_hex,
+ chain_str,
+ None,
+ 1.01,
+ ],
+ queue=self.queue,
+ )
+ else:
+ raise NotImplementedError('resend as new not yet implemented')
+
+ if unlock:
+ s_gas = celery.signature(
+ 'cic_eth.admin.ctrl.unlock_send',
+ [
+ chain_str,
+ tx_dict['sender'],
+ ],
+ queue=self.queue,
+ )
+ s.link(s_gas)
+
+ return s.apply_async()
+
+ def check_nonce(self, address):
+ s = celery.signature(
+ 'cic_eth.queue.tx.get_account_tx',
+ [
+ address,
+ True,
+ False,
+ ],
+ queue=self.queue,
+ )
+ txs = s.apply_async().get()
+
+ blocking_tx = None
+ blocking_nonce = None
+ nonce_otx = 0
+ for k in txs.keys():
+ s_get_tx = celery.signature(
+ 'cic_eth.queue.tx.get_tx',
+ [
+ k,
+ ],
+ queue=self.queue,
+ )
+ tx = s_get_tx.apply_async().get()
+ #tx = get_tx(k)
+ logg.debug('checking nonce {}'.format(tx['nonce']))
+ if tx['status'] in [StatusEnum.REJECTED, StatusEnum.FUBAR]:
+ blocking_tx = k
+ blocking_nonce = tx['nonce']
+ nonce_otx = tx['nonce']
+
+ #nonce_cache = Nonce.get(address)
+ nonce_w3 = self.w3.eth.getTransactionCount(address, 'pending')
+
+ return {
+ 'nonce': {
+ 'network': nonce_w3,
+ 'queue': nonce_otx,
+ #'cache': nonce_cache,
+ 'blocking': blocking_nonce,
+ },
+ 'tx': {
+ 'blocking': blocking_tx,
+ }
+ }
+
+
+ def fix_nonce(self, address, nonce):
+ s = celery.signature(
+ 'cic_eth.queue.tx.get_account_tx',
+ [
+ address,
+ True,
+ False,
+ ],
+ queue=self.queue,
+ )
+ txs = s.apply_async().get()
+
+ tx_hash_hex = None
+ for k in txs.keys():
+ tx_dict = get_tx(k)
+ if tx_dict['nonce'] == nonce:
+ tx_hash_hex = k
+
+ s_nonce = celery.signature(
+ 'cic_eth.admin.nonce.shift_nonce',
+ [
+ str(self.rpc_client.chain_spec),
+ tx_hash_hex,
+ ],
+ queue=self.queue
+ )
+ return s_nonce.apply_async()
+
+
+ # TODO: this is a stub, complete all checks
+ def ready(self):
+ """Checks whether all required initializations have been performed.
+
+ :raises cic_eth.error.InitializationError: At least one setting pre-requisite has not been met.
+ :raises KeyError: An address provided for initialization is not known by the keystore.
+ """
+ addr = AccountRole.get_address('ETH_GAS_PROVIDER_ADDRESS')
+ if addr == zero_address:
+ raise InitializationError('missing account ETH_GAS_PROVIDER_ADDRESS')
+
+ self.w3.eth.sign(addr, text='666f6f')
+
+
+ def account(self, chain_spec, address, cols=['tx_hash', 'sender', 'recipient', 'nonce', 'block', 'tx_index', 'status', 'network_status', 'date_created'], include_sender=True, include_recipient=True):
+ """Lists locally originated transactions for the given Ethereum address.
+
+ Performs a synchronous call to the Celery task responsible for performing the query.
+
+ :param address: Ethereum address to return transactions for
+ :type address: str, 0x-hex
+ :param cols: Data columns to include
+ :type cols: list of str
+ """
+ s = celery.signature(
+ 'cic_eth.queue.tx.get_account_tx',
+ [address],
+ queue=self.queue,
+ )
+ txs = s.apply_async().get()
+
+ tx_dict_list = []
+ for tx_hash in txs.keys():
+ s = celery.signature(
+ 'cic_eth.queue.tx.get_tx_cache',
+ [tx_hash],
+ queue=self.queue,
+ )
+ tx_dict = s.apply_async().get()
+ if tx_dict['sender'] == address and not include_sender:
+ logg.debug('skipping sender tx {}'.format(tx_dict['tx_hash']))
+ continue
+ elif tx_dict['recipient'] == address and not include_recipient:
+ logg.debug('skipping recipient tx {}'.format(tx_dict['tx_hash']))
+ continue
+
+ logg.debug(tx_dict)
+ o = {
+ 'nonce': tx_dict['nonce'],
+ 'tx_hash': tx_dict['tx_hash'],
+ 'status': tx_dict['status'],
+ 'date_updated': tx_dict['date_updated'],
+ }
+ tx_dict_list.append(o)
+
+ return tx_dict_list
+
+
+ # TODO: Add exception upon non-existent tx aswell as invalid tx data to docstring
+ def tx(self, chain_spec, tx_hash=None, tx_raw=None):
+ """Output local and network details about a given transaction with local origin.
+
+ If the transaction hash is given, the raw trasnaction data will be retrieved from the local transaction queue backend. Otherwise the raw transaction data must be provided directly. Only one of transaction hash and transaction data can be passed.
+
+ :param chain_spec: Chain spec of the transaction's chain context
+ :type chain_spec: cic_registry.chain.ChainSpec
+ :param tx_hash: Transaction hash of transaction to parse and view
+ :type tx_hash: str, 0x-hex
+ :param tx_raw: Signed raw transaction data to parse and view
+ :type tx_raw: str, 0x-hex
+ :raises ValueError: Both tx_hash and tx_raw are passed
+ :return: Transaction details
+ :rtype: dict
+ """
+ if tx_hash != None and tx_raw != None:
+ ValueError('Specify only one of hash or raw tx')
+
+ if tx_raw != None:
+ tx_hash = self.w3.keccak(hexstr=tx_raw).hex()
+
+ s = celery.signature(
+ 'cic_eth.queue.tx.get_tx_cache',
+ [tx_hash],
+ queue=self.queue,
+ )
+
+ tx = s.apply_async().get()
+
+ source_token = None
+ if tx['source_token'] != zero_address:
+ try:
+ source_token = CICRegistry.get_address(chain_spec, tx['source_token']).contract
+ except UnknownContractError:
+ source_token_contract = self.w3.eth.contract(abi=CICRegistry.abi('ERC20'), address=tx['source_token'])
+ source_token = CICRegistry.add_token(chain_spec, source_token_contract)
+ logg.warning('unknown source token contract {}'.format(tx['source_token']))
+
+ destination_token = None
+ if tx['source_token'] != zero_address:
+ try:
+ destination_token = CICRegistry.get_address(chain_spec, tx['destination_token'])
+ except UnknownContractError:
+ destination_token_contract = self.w3.eth.contract(abi=CICRegistry.abi('ERC20'), address=tx['source_token'])
+ destination_token = CICRegistry.add_token(chain_spec, destination_token_contract)
+ logg.warning('unknown destination token contract {}'.format(tx['destination_token']))
+
+ tx['sender_description'] = 'Custodial account'
+ tx['recipient_description'] = 'Custodial account'
+
+ c = RpcClient(chain_spec)
+ if len(c.w3.eth.getCode(tx['sender'])) > 0:
+ try:
+ sender_contract = CICRegistry.get_address(chain_spec, tx['sender'])
+ tx['sender_description'] = 'Contract {}'.format(sender_contract.identifier())
+ except UnknownContractError:
+ tx['sender_description'] = 'Unknown contract'
+ except KeyError as e:
+ tx['sender_description'] = 'Unknown contract'
+ else:
+ s = celery.signature(
+ 'cic_eth.eth.account.have',
+ [
+ tx['sender'],
+ str(chain_spec),
+ ],
+ queue=self.queue,
+ )
+ t = s.apply_async()
+ account = t.get()
+ if account == None:
+ tx['sender_description'] = 'Unknown account'
+ else:
+ s = celery.signature(
+ 'cic_eth.eth.account.role',
+ [
+ tx['sender'],
+ str(chain_spec),
+ ],
+ queue=self.queue,
+ )
+ t = s.apply_async()
+ role = t.get()
+ if role != None:
+ tx['sender_description'] = role
+
+
+ if len(c.w3.eth.getCode(tx['recipient'])) > 0:
+ try:
+ recipient_contract = CICRegistry.get_address(chain_spec, tx['recipient'])
+ tx['recipient_description'] = 'Contract {}'.format(recipient_contract.identifier())
+ except UnknownContractError as e:
+ tx['recipient_description'] = 'Unknown contract'
+ except KeyError as e:
+ tx['recipient_description'] = 'Unknown contract'
+ else:
+ s = celery.signature(
+ 'cic_eth.eth.account.have',
+ [
+ tx['recipient'],
+ str(chain_spec),
+ ],
+ queue=self.queue,
+ )
+ t = s.apply_async()
+ account = t.get()
+ if account == None:
+ tx['recipient_description'] = 'Unknown account'
+ else:
+ s = celery.signature(
+ 'cic_eth.eth.account.role',
+ [
+ tx['recipient'],
+ str(chain_spec),
+ ],
+ queue=self.queue,
+ )
+ t = s.apply_async()
+ role = t.get()
+ if role != None:
+ tx['recipient_description'] = role
+
+ if source_token != None:
+ tx['source_token_symbol'] = source_token.symbol()
+ tx['sender_token_balance'] = source_token.function('balanceOf')(tx['sender']).call()
+
+ if destination_token != None:
+ tx['destination_token_symbol'] = destination_token.symbol()
+ tx['recipient_token_balance'] = source_token.function('balanceOf')(tx['recipient']).call()
+
+ tx['network_status'] = 'Not submitted'
+
+ try:
+ c.w3.eth.getTransaction(tx_hash)
+ tx['network_status'] = 'Mempool'
+ except web3.exceptions.TransactionNotFound:
+ pass
+
+ try:
+ r = c.w3.eth.getTransactionReceipt(tx_hash)
+ if r.status == 1:
+ tx['network_status'] = 'Confirmed'
+ tx['block'] = r.blockNumber
+ tx['tx_index'] = r.transactionIndex
+ else:
+ tx['network_status'] = 'Reverted'
+ except web3.exceptions.TransactionNotFound:
+ pass
+
+ tx['sender_gas_balance'] = c.w3.eth.getBalance(tx['sender'])
+ tx['recipient_gas_balance'] = c.w3.eth.getBalance(tx['recipient'])
+
+ tx_unpacked = unpack_signed_raw_tx(bytes.fromhex(tx['signed_tx'][2:]), chain_spec.chain_id())
+ tx['gas_price'] = tx_unpacked['gasPrice']
+ tx['gas_limit'] = tx_unpacked['gas']
+
+ s = celery.signature(
+ 'cic_eth.queue.tx.get_state_log',
+ [
+ tx_hash,
+ ],
+ queue=self.queue,
+ )
+ t = s.apply_async()
+ tx['status_log'] = t.get()
+
+ return tx
diff --git a/apps/cic-eth/cic_eth/api/api_task.py b/apps/cic-eth/cic_eth/api/api_task.py
new file mode 100644
index 00000000..eca5f915
--- /dev/null
+++ b/apps/cic-eth/cic_eth/api/api_task.py
@@ -0,0 +1,431 @@
+"""API for cic-eth celery tasks
+
+.. moduleauthor:: Louis Holbrook
+
+"""
+# standard imports
+import logging
+
+# third-party imports
+import celery
+from cic_registry.chain import ChainSpec
+from cic_registry import CICRegistry
+from cic_eth.eth.factory import TxFactory
+from cic_eth.db.enum import LockEnum
+
+app = celery.current_app
+
+logg = logging.getLogger(__name__)
+
+
+class Api:
+ """Creates task chains to perform well-known CIC operations.
+
+ Each method that sends tasks returns details about the root task. The root task uuid can be provided in the callback, to enable to caller to correlate the result with individual calls. It can also be used to independently poll the completion of a task chain.
+
+ :param callback_param: Static value to pass to callback
+ :type callback_param: str
+ :param callback_task: Callback task that executes callback_param call. (Must be included by the celery worker)
+ :type callback_task: string
+ :param queue: Name of worker queue to submit tasks to
+ :type queue: str
+ """
+ def __init__(self, chain_str, queue='cic-eth', callback_param=None, callback_task='cic_eth.callbacks.noop', callback_queue=None):
+ self.chain_str = chain_str
+ self.chain_spec = ChainSpec.from_chain_str(chain_str)
+ self.callback_param = callback_param
+ self.callback_task = callback_task
+ self.queue = queue
+ logg.info('api using queue {}'.format(self.queue))
+ self.callback_success = None
+ self.callback_error = None
+ if callback_queue == None:
+ callback_queue=self.queue
+
+ if callback_param != None:
+ self.callback_success = celery.signature(
+ callback_task,
+ [
+ callback_param,
+ 0,
+ ],
+ queue=callback_queue,
+ )
+ self.callback_error = celery.signature(
+ callback_task,
+ [
+ callback_param,
+ 1,
+ ],
+ queue=callback_queue,
+ )
+
+
+ def convert_transfer(self, from_address, to_address, target_return, minimum_return, from_token_symbol, to_token_symbol):
+ """Executes a chain of celery tasks that performs conversion between two ERC20 tokens, and transfers to a specified receipient after convert has completed.
+
+ :param from_address: Ethereum address of sender
+ :type from_address: str, 0x-hex
+ :param to_address: Ethereum address of receipient
+ :type to_address: str, 0x-hex
+ :param target_return: Estimated return from conversion
+ :type target_return: int
+ :param minimum_return: The least value of destination token return to allow
+ :type minimum_return: int
+ :param from_token_symbol: ERC20 token symbol of token being converted
+ :type from_token_symbol: str
+ :param to_token_symbol: ERC20 token symbol of token to receive
+ :type to_token_symbol: str
+ :returns: uuid of root task
+ :rtype: celery.Task
+ """
+ s_check = celery.signature(
+ 'cic_eth.admin.ctrl.check_lock',
+ [
+ [from_token_symbol, to_token_symbol],
+ self.chain_str,
+ LockEnum.QUEUE,
+ from_address,
+ ],
+ queue=self.queue,
+ )
+ s_tokens = celery.signature(
+ 'cic_eth.eth.token.resolve_tokens_by_symbol',
+ [
+ self.chain_str,
+ ],
+ queue=self.queue,
+ )
+ s_convert = celery.signature(
+ 'cic_eth.eth.bancor.convert_with_default_reserve',
+ [
+ from_address,
+ target_return,
+ minimum_return,
+ to_address,
+ self.chain_str,
+ ],
+ queue=self.queue,
+ )
+ s_check.link(s_tokens)
+ if self.callback_param != None:
+ s_convert.link(self.callback_success)
+ s_tokens.link(s_convert).on_error(self.callback_error)
+ else:
+ s_tokens.link(s_convert)
+
+ t = s_check.apply_async(queue=self.queue)
+ return t
+
+
+ def convert(self, from_address, target_return, minimum_return, from_token_symbol, to_token_symbol):
+ """Executes a chain of celery tasks that performs conversion between two ERC20 tokens.
+
+ :param from_address: Ethereum address of sender
+ :type from_address: str, 0x-hex
+ :param target_return: Estimated return from conversion
+ :type target_return: int
+ :param minimum_return: The least value of destination token return to allow
+ :type minimum_return: int
+ :param from_token_symbol: ERC20 token symbol of token being converted
+ :type from_token_symbol: str
+ :param to_token_symbol: ERC20 token symbol of token to receive
+ :type to_token_symbol: str
+ :returns: uuid of root task
+ :rtype: celery.Task
+ """
+ s_check = celery.signature(
+ 'cic_eth.admin.ctrl.check_lock',
+ [
+ [from_token_symbol, to_token_symbol],
+ self.chain_str,
+ LockEnum.QUEUE,
+ from_address,
+ ],
+ queue=self.queue,
+ )
+ s_tokens = celery.signature(
+ 'cic_eth.eth.token.resolve_tokens_by_symbol',
+ [
+ self.chain_str,
+ ],
+ queue=self.queue,
+ )
+ s_convert = celery.signature(
+ 'cic_eth.eth.bancor.convert_with_default_reserve',
+ [
+ from_address,
+ target_return,
+ minimum_return,
+ from_address,
+ self.chain_str,
+ ],
+ queue=self.queue,
+ )
+ s_check.link(s_tokens)
+ if self.callback_param != None:
+ s_convert.link(self.callback_success)
+ s_tokens.link(s_convert).on_error(self.callback_error)
+ else:
+ s_tokens.link(s_convert)
+
+ t = s_check.apply_async(queue=self.queue)
+ return t
+
+
+ def transfer(self, from_address, to_address, value, token_symbol):
+ """Executes a chain of celery tasks that performs a transfer of ERC20 tokens from one address to another.
+
+ :param from_address: Ethereum address of sender
+ :type from_address: str, 0x-hex
+ :param to_address: Ethereum address of recipient
+ :type to_address: str, 0x-hex
+ :param value: Estimated return from conversion
+ :type value: int
+ :param token_symbol: ERC20 token symbol of token to send
+ :type token_symbol: str
+ :returns: uuid of root task
+ :rtype: celery.Task
+ """
+ s_check = celery.signature(
+ 'cic_eth.admin.ctrl.check_lock',
+ [
+ [token_symbol],
+ self.chain_str,
+ LockEnum.QUEUE,
+ from_address,
+ ],
+ queue=self.queue,
+ )
+ s_tokens = celery.signature(
+ 'cic_eth.eth.token.resolve_tokens_by_symbol',
+ [
+ self.chain_str,
+ ],
+ queue=self.queue,
+ )
+ s_transfer = celery.signature(
+ 'cic_eth.eth.token.transfer',
+ [
+ from_address,
+ to_address,
+ value,
+ self.chain_str,
+ ],
+ queue=self.queue,
+ )
+ s_check.link(s_tokens)
+ if self.callback_param != None:
+ s_transfer.link(self.callback_success)
+ s_tokens.link(s_transfer).on_error(self.callback_error)
+ else:
+ s_tokens.link(s_transfer)
+
+ t = s_check.apply_async(queue=self.queue)
+ return t
+
+
+ def transfer_request(self, from_address, to_address, spender_address, value, token_symbol):
+ """Executes a chain of celery tasks that issues a transfer request of ERC20 tokens from one address to another.
+
+ :param from_address: Ethereum address of sender
+ :type from_address: str, 0x-hex
+ :param to_address: Ethereum address of recipient
+ :type to_address: str, 0x-hex
+ :param spender_address: Ethereum address that is executing transfer (typically an escrow contract)
+ :type spender_address: str, 0x-hex
+ :param value: Estimated return from conversion
+ :type value: int
+ :param token_symbol: ERC20 token symbol of token to send
+ :type token_symbol: str
+ :returns: uuid of root task
+ :rtype: celery.Task
+ """
+ s_check = celery.signature(
+ 'cic_eth.admin.ctrl.check_lock',
+ [
+ [token_symbol],
+ self.chain_str,
+ LockEnum.QUEUE,
+ from_address,
+ ],
+ queue=self.queue,
+ )
+ s_tokens_transfer_approval = celery.signature(
+ 'cic_eth.eth.token.resolve_tokens_by_symbol',
+ [
+ self.chain_str,
+ ],
+ queue=self.queue,
+ )
+ s_tokens_approve = celery.signature(
+ 'cic_eth.eth.token.resolve_tokens_by_symbol',
+ [
+ self.chain_str,
+ ],
+ queue=self.queue,
+ )
+ s_approve = celery.signature(
+ 'cic_eth.eth.token.approve',
+ [
+ from_address,
+ spender_address,
+ value,
+ self.chain_str,
+ ],
+ queue=self.queue,
+ )
+ s_transfer_approval = celery.signature(
+ 'cic_eth.eth.request.transfer_approval_request',
+ [
+ from_address,
+ to_address,
+ value,
+ self.chain_str,
+ ],
+ queue=self.queue,
+ )
+ # TODO: make approve and transfer_approval chainable so callback can be part of the full chain
+ if self.callback_param != None:
+ s_transfer_approval.link(self.callback_success)
+ s_tokens_approve.link(s_approve)
+ s_tokens_transfer_approval.link(s_transfer_approval).on_error(self.callback_error)
+ else:
+ s_tokens_approve.link(s_approve)
+ s_tokens_transfer_approval.link(s_transfer_approval)
+
+ g = celery.group(s_tokens_approve, s_tokens_transfer_approval) #s_tokens.apply_async(queue=self.queue)
+ s_check.link(g)
+ t = s_check.apply_async()
+ #t = s_tokens.apply_async(queue=self.queue)
+ return t
+
+
+ def balance(self, address, token_symbol):
+ """Calls the provided callback with the current token balance of the given address.
+
+ :param address: Ethereum address of holder
+ :type address: str, 0x-hex
+ :param token_symbol: ERC20 token symbol of token to send
+ :type token_symbol: str
+ :returns: uuid of root task
+ :rtype: celery.Task
+ """
+ if self.callback_param == None:
+ logg.warning('balance pointlessly called with no callback url')
+
+ s_tokens = celery.signature(
+ 'cic_eth.eth.token.resolve_tokens_by_symbol',
+ [
+ [token_symbol],
+ self.chain_str,
+ ],
+ queue=self.queue,
+ )
+ s_balance = celery.signature(
+ 'cic_eth.eth.token.balance',
+ [
+ address,
+ self.chain_str,
+ ],
+ queue=self.queue,
+ )
+
+ if self.callback_param != None:
+ s_balance.link(self.callback_success)
+ s_tokens.link(s_balance).on_error(self.callback_error)
+ else:
+ s_tokens.link(s_balance)
+
+ t = s_tokens.apply_async(queue=self.queue)
+ return t
+
+
+ def create_account(self, password='', register=True):
+ """Creates a new blockchain address encrypted with the given password, and calls the provided callback with the address of the new account.
+
+ :param password: Password to encode the password with in the backend (careful, you will have to remember it)
+ :type password: str
+ :param register: Register the new account in accounts index backend
+ :type password: bool
+ :returns: uuid of root task
+ :rtype: celery.Task
+ """
+ s_check = celery.signature(
+ 'cic_eth.admin.ctrl.check_lock',
+ [
+ password,
+ self.chain_str,
+ LockEnum.CREATE,
+ ],
+ queue=self.queue,
+ )
+ s_account = celery.signature(
+ 'cic_eth.eth.account.create',
+ [
+ self.chain_str,
+ ],
+ queue=self.queue,
+ )
+ s_check.link(s_account)
+ if self.callback_param != None:
+ s_account.link(self.callback_success)
+
+ if register:
+ s_register = celery.signature(
+ 'cic_eth.eth.account.register',
+ [
+ self.chain_str,
+ ],
+ queue=self.queue,
+ )
+ s_account.link(s_register)
+
+ t = s_check.apply_async(queue=self.queue)
+ return t
+
+
+ def refill_gas(self, address):
+ """Creates a new gas refill transaction with the registered gas provider address.
+
+ :param address: Ethereum address to send gas tokens to.
+ :type address: str
+ :returns: uuid of root task
+ :rtype: celery.Task
+ """
+ s_check = celery.signature(
+ 'cic_eth.admin.ctrl.check_lock',
+ [
+ address,
+ self.chain_str,
+ LockEnum.QUEUE,
+ ],
+ queue=self.queue,
+ )
+ s_refill = celery.signature(
+ 'cic_eth.eth.tx.refill_gas',
+ [
+ self.chain_str,
+ ],
+ queue=self.queue,
+ )
+ s_check.link(s_refill)
+ if self.callback_param != None:
+ s_refill.link(self.callback_success)
+
+ t = s_check.apply_async(queue=self.queue)
+ return t
+
+
+ def ping(self, r):
+ """A noop callback ping for testing purposes.
+
+ :returns: uuid of callback task
+ :rtype: celery.Task
+ """
+ if self.callback_param == None:
+ logg.warning('nothing to do')
+ return None
+
+ t = self.callback_success.apply_async([r])
+ return t
diff --git a/apps/cic-eth/cic_eth/callbacks/__init__.py b/apps/cic-eth/cic_eth/callbacks/__init__.py
new file mode 100644
index 00000000..45bea60d
--- /dev/null
+++ b/apps/cic-eth/cic_eth/callbacks/__init__.py
@@ -0,0 +1 @@
+from .callback import Callback
diff --git a/apps/cic-eth/cic_eth/callbacks/callback.py b/apps/cic-eth/cic_eth/callbacks/callback.py
new file mode 100644
index 00000000..4ca56e3a
--- /dev/null
+++ b/apps/cic-eth/cic_eth/callbacks/callback.py
@@ -0,0 +1,16 @@
+# third-party imports
+import celery
+
+class Callback(celery.Task):
+ """Provides static properties for web connection context. The properties should be set directly.
+ """
+ ssl = False
+ """If true, a SSL client certificate with default protocol for standard library ssl will be used for the HTTP connection."""
+ ssl_cert_file = None
+ """Absolute path to client certificate PEM file"""
+ ssl_key_file = None
+ """Absolute path to client key file"""
+ ssl_password=None
+ """Password to unlock key file"""
+ ssl_ca_file = None
+ """Client certificate CA chain"""
diff --git a/apps/cic-eth/cic_eth/callbacks/http.py b/apps/cic-eth/cic_eth/callbacks/http.py
new file mode 100644
index 00000000..f06982e5
--- /dev/null
+++ b/apps/cic-eth/cic_eth/callbacks/http.py
@@ -0,0 +1,64 @@
+# standard imports
+import json
+import ssl
+import os
+import urllib
+from urllib import request
+from urllib.request import urlopen
+
+# third-party imports
+from . import Callback
+import celery
+
+celery_app = celery.current_app
+logg = celery_app.log.get_default_logger()
+
+
+@celery_app.task(base=Callback, bind=True)
+def http(self, result, url, status_code):
+ """A generic web callback implementation for task results.
+
+ Input parameters depend on whether the callback is used as an error callback, or as a part of a celery chain.
+
+ The callback receives:
+
+ {
+ 'root_id': the uuid of the topmost task in the chain, which is known to the API caller.
+ 'status': ,
+ 'result': ,
+ }
+
+ :param result: Task context object (on error) or return value of previous task (on success)
+ :type result: Varies
+ :param url: Url to HTTP POST results to
+ :type url: str
+ :param status_code: 0 on success, any other value is error
+ :type status_code: int
+ """
+ req = request.Request(url)
+ data = {
+ 'root_id': self.request.root_id,
+ 'status': status_code,
+ 'result': result,
+ }
+ data_str = json.dumps(data)
+ data_bytes = data_str.encode('utf-8')
+ req.add_header('Content-Type', 'application/json')
+ req.data = data_bytes
+
+ ctx = None
+ if self.ssl:
+ ctx = ssl.SSLContext()
+ ctx.load_cert_chain(
+ self.ssl_cert_file,
+ self.ssl_key_file,
+ self.ssl_password,
+ )
+
+ response = urlopen(
+ req,
+ context=ctx,
+ )
+
+ if response.status != 200:
+ raise RuntimeError('Expected status 200 from remote server, but got {} {}'.format(response.status, response.msg))
diff --git a/apps/cic-eth/cic_eth/callbacks/noop.py b/apps/cic-eth/cic_eth/callbacks/noop.py
new file mode 100644
index 00000000..b064e40d
--- /dev/null
+++ b/apps/cic-eth/cic_eth/callbacks/noop.py
@@ -0,0 +1,21 @@
+import celery
+
+celery_app = celery.current_app
+logg = celery_app.log.get_default_logger()
+
+
+@celery_app.task(bind=True)
+def noop(self, result, param, status_code):
+ """A noop callback for task chains executed by external api methods. Logs the callback arguments.
+
+ :param result: Task context object (on error) or return value of previous task (on success)
+ :type result: Varies
+ :param param: Static value passed from api caller
+ :type param: Varies
+ :param status_code: 0 on success, any other value is error
+ :type status_code: int
+ :returns: True
+ :rtype: bool
+ """
+ logg.info('noop callback {} {} {}'.format(result, param, status_code))
+ return True
diff --git a/apps/cic-eth/cic_eth/callbacks/redis.py b/apps/cic-eth/cic_eth/callbacks/redis.py
new file mode 100644
index 00000000..648edabb
--- /dev/null
+++ b/apps/cic-eth/cic_eth/callbacks/redis.py
@@ -0,0 +1,24 @@
+# standard imports
+import logging
+import json
+import redis as redis_interface
+
+# third-party imports
+import celery
+
+# local imports
+from . import Callback
+
+celery_app = celery.current_app
+
+logg = celery_app.log.get_default_logger()
+
+
+@celery_app.task(base=Callback, bind=True)
+def redis(self, result, destination, status_code):
+ (host, port, db, channel) = destination.split(':')
+ r = redis_interface.Redis(host=host, port=port, db=db)
+ s = json.dumps(result)
+ logg.debug('redis callback on host {} port {} db {} channel {}'.format(host, port, db, channel))
+ r.publish(channel, s)
+ r.close()
diff --git a/apps/cic-eth/cic_eth/callbacks/tcp.py b/apps/cic-eth/cic_eth/callbacks/tcp.py
new file mode 100644
index 00000000..9cd79938
--- /dev/null
+++ b/apps/cic-eth/cic_eth/callbacks/tcp.py
@@ -0,0 +1,24 @@
+# standard imports
+import socket
+import logging
+import json
+
+# third-party imports
+import celery
+
+# local imports
+from . import Callback
+
+celery_app = celery.current_app
+
+logg = celery_app.log.get_default_logger()
+
+
+@celery_app.task(base=Callback, bind=True)
+def tcp(self, result, destination, status_code):
+ s = socket.socket(family=socket.AF_INET, type=socket.SOCK_STREAM)
+ (host, port) = destination.split(':')
+ logg.debug('tcp callback to {} {}'.format(host, port))
+ s.connect((host, int(port)))
+ s.send(json.dumps(result).encode('utf-8'))
+ s.close()
diff --git a/apps/cic-eth/cic_eth/db/__init__.py b/apps/cic-eth/cic_eth/db/__init__.py
new file mode 100644
index 00000000..1a549508
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/__init__.py
@@ -0,0 +1,61 @@
+# standard imports
+import os
+import logging
+
+# local imports
+from cic_eth.db.models.base import SessionBase
+
+logg = logging.getLogger()
+
+
+# an Engine, which the Session will use for connection
+# resources
+
+# TODO: Remove the package exports, all models should be imported using full path
+from .models.otx import Otx
+from .models.convert import TxConvertTransfer
+
+
+def dsn_from_config(config):
+ """Generate a dsn string from the provided config dict.
+
+ The config dict must include all well-known database connection parameters, and must implement the method "get(key)" to retrieve them. Any missing parameters will be be rendered as the literal string "None"
+
+ :param config: Configuration object
+ :type config: Varies
+ :returns: dsn string
+ :rtype: str
+ """
+ scheme = config.get('DATABASE_ENGINE')
+ if config.get('DATABASE_DRIVER') != None:
+ scheme += '+{}'.format(config.get('DATABASE_DRIVER'))
+
+ dsn = ''
+ dsn_out = ''
+ if config.get('DATABASE_ENGINE') == 'sqlite':
+ dsn = '{}:///{}'.format(
+ scheme,
+ config.get('DATABASE_NAME'),
+ )
+ dsn_out = dsn
+
+ else:
+ dsn = '{}://{}:{}@{}:{}/{}'.format(
+ scheme,
+ config.get('DATABASE_USER'),
+ config.get('DATABASE_PASSWORD'),
+ config.get('DATABASE_HOST'),
+ config.get('DATABASE_PORT'),
+ config.get('DATABASE_NAME'),
+ )
+ dsn_out = '{}://{}:{}@{}:{}/{}'.format(
+ scheme,
+ config.get('DATABASE_USER'),
+ '***',
+ config.get('DATABASE_HOST'),
+ config.get('DATABASE_PORT'),
+ config.get('DATABASE_NAME'),
+ )
+ logg.debug('parsed dsn from config: {}'.format(dsn_out))
+ return dsn
+
diff --git a/apps/cic-eth/cic_eth/db/enum.py b/apps/cic-eth/cic_eth/db/enum.py
new file mode 100644
index 00000000..c835cac3
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/enum.py
@@ -0,0 +1,51 @@
+# standard imports
+import enum
+
+class StatusEnum(enum.IntEnum):
+ """
+
+ - Inactive, not finalized. (<0)
+ * PENDING: The initial state of a newly added transaction record. No action has been performed on this transaction yet.
+ * SENDFAIL: The transaction was not received by the node.
+ * RETRY: The transaction is queued for a new send attempt after previously failing.
+ * READYSEND: The transaction is queued for its first send attempt
+ * OBSOLETED: A new transaction with the same nonce and higher gas has been sent to network.
+ * WAITFORGAS: The transaction is on hold pending gas funding.
+ - Active state: (==0)
+ * SENT: The transaction has been sent to the mempool.
+ - Inactive, finalized. (>0)
+ * FUBAR: Unknown error occurred and transaction is abandoned. Manual intervention needed.
+ * CANCELLED: The transaction was sent, but was not mined and has disappered from the mempool. This usually follows a transaction being obsoleted.
+ * OVERRIDDEN: Transaction has been manually overriden.
+ * REJECTED: The transaction was rejected by the node.
+ * REVERTED: The transaction was mined, but exception occurred during EVM execution. (Block number will be set)
+ * SUCCESS: THe transaction was successfully mined. (Block number will be set)
+
+ """
+ PENDING=-9
+ SENDFAIL=-8
+ RETRY=-7
+ READYSEND=-6
+ OBSOLETED=-2
+ WAITFORGAS=-1
+ SENT=0
+ FUBAR=1
+ CANCELLED=2
+ OVERRIDDEN=3
+ REJECTED=7
+ REVERTED=8
+ SUCCESS=9
+
+
+class LockEnum(enum.IntEnum):
+ """
+ STICKY: When set, reset is not possible
+ CREATE: Disable creation of accounts
+ SEND: Disable sending to network
+ QUEUE: Disable queueing new or modified transactions
+ """
+ STICKY=1
+ CREATE=2
+ SEND=4
+ QUEUE=8
+ ALL=int(0xfffffffffffffffe)
diff --git a/apps/cic-eth/cic_eth/db/error.py b/apps/cic-eth/cic_eth/db/error.py
new file mode 100644
index 00000000..29b89f01
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/error.py
@@ -0,0 +1,9 @@
+class TxStateChangeError(Exception):
+ """Raised when an invalid state change of a queued transaction occurs
+ """
+ pass
+
+
+class UnknownConvertError(Exception):
+ """Raised when a non-existent convert to transaction subtask is requested
+ """
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/README b/apps/cic-eth/cic_eth/db/migrations/default/README
new file mode 100644
index 00000000..98e4f9c4
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/README
@@ -0,0 +1 @@
+Generic single-database configuration.
\ No newline at end of file
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/alembic.ini b/apps/cic-eth/cic_eth/db/migrations/default/alembic.ini
new file mode 100644
index 00000000..1555f68c
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/alembic.ini
@@ -0,0 +1,85 @@
+# A generic, single database configuration.
+
+[alembic]
+# path to migration scripts
+script_location = .
+
+# template used to generate migration files
+# file_template = %%(rev)s_%%(slug)s
+
+# timezone to use when rendering the date
+# within the migration file as well as the filename.
+# string value is passed to dateutil.tz.gettz()
+# leave blank for localtime
+# timezone =
+
+# max length of characters to apply to the
+# "slug" field
+# truncate_slug_length = 40
+
+# set to 'true' to run the environment during
+# the 'revision' command, regardless of autogenerate
+# revision_environment = false
+
+# set to 'true' to allow .pyc and .pyo files without
+# a source .py file to be detected as revisions in the
+# versions/ directory
+# sourceless = false
+
+# version location specification; this defaults
+# to migrations/versions. When using multiple version
+# directories, initial revisions must be specified with --version-path
+# version_locations = %(here)s/bar %(here)s/bat migrations/versions
+
+# the output encoding used when revision files
+# are written from script.py.mako
+# output_encoding = utf-8
+
+#sqlalchemy.url = driver://user:pass@localhost/dbname
+sqlalchemy.url = postgresql+psycopg2://postgres@localhost:5432/cic-eth
+
+[post_write_hooks]
+# post_write_hooks defines scripts or Python functions that are run
+# on newly generated revision scripts. See the documentation for further
+# detail and examples
+
+# format using "black" - use the console_scripts runner, against the "black" entrypoint
+# hooks=black
+# black.type=console_scripts
+# black.entrypoint=black
+# black.options=-l 79
+
+# Logging configuration
+[loggers]
+keys = root,sqlalchemy,alembic
+
+[handlers]
+keys = console
+
+[formatters]
+keys = generic
+
+[logger_root]
+level = WARN
+handlers = console
+qualname =
+
+[logger_sqlalchemy]
+level = WARN
+handlers =
+qualname = sqlalchemy.engine
+
+[logger_alembic]
+level = INFO
+handlers =
+qualname = alembic
+
+[handler_console]
+class = StreamHandler
+args = (sys.stderr,)
+level = NOTSET
+formatter = generic
+
+[formatter_generic]
+format = %(levelname)-5.5s [%(name)s] %(message)s
+datefmt = %H:%M:%S
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/env.py b/apps/cic-eth/cic_eth/db/migrations/default/env.py
new file mode 100644
index 00000000..70518a2e
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/env.py
@@ -0,0 +1,77 @@
+from logging.config import fileConfig
+
+from sqlalchemy import engine_from_config
+from sqlalchemy import pool
+
+from alembic import context
+
+# this is the Alembic Config object, which provides
+# access to the values within the .ini file in use.
+config = context.config
+
+# Interpret the config file for Python logging.
+# This line sets up loggers basically.
+fileConfig(config.config_file_name)
+
+# add your model's MetaData object here
+# for 'autogenerate' support
+# from myapp import mymodel
+# target_metadata = mymodel.Base.metadata
+target_metadata = None
+
+# other values from the config, defined by the needs of env.py,
+# can be acquired:
+# my_important_option = config.get_main_option("my_important_option")
+# ... etc.
+
+
+def run_migrations_offline():
+ """Run migrations in 'offline' mode.
+
+ This configures the context with just a URL
+ and not an Engine, though an Engine is acceptable
+ here as well. By skipping the Engine creation
+ we don't even need a DBAPI to be available.
+
+ Calls to context.execute() here emit the given string to the
+ script output.
+
+ """
+ url = config.get_main_option("sqlalchemy.url")
+ context.configure(
+ url=url,
+ target_metadata=target_metadata,
+ literal_binds=True,
+ dialect_opts={"paramstyle": "named"},
+ )
+
+ with context.begin_transaction():
+ context.run_migrations()
+
+
+def run_migrations_online():
+ """Run migrations in 'online' mode.
+
+ In this scenario we need to create an Engine
+ and associate a connection with the context.
+
+ """
+ connectable = engine_from_config(
+ config.get_section(config.config_ini_section),
+ prefix="sqlalchemy.",
+ poolclass=pool.NullPool,
+ )
+
+ with connectable.connect() as connection:
+ context.configure(
+ connection=connection, target_metadata=target_metadata
+ )
+
+ with context.begin_transaction():
+ context.run_migrations()
+
+
+if context.is_offline_mode():
+ run_migrations_offline()
+else:
+ run_migrations_online()
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/script.py.mako b/apps/cic-eth/cic_eth/db/migrations/default/script.py.mako
new file mode 100644
index 00000000..2c015630
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/script.py.mako
@@ -0,0 +1,24 @@
+"""${message}
+
+Revision ID: ${up_revision}
+Revises: ${down_revision | comma,n}
+Create Date: ${create_date}
+
+"""
+from alembic import op
+import sqlalchemy as sa
+${imports if imports else ""}
+
+# revision identifiers, used by Alembic.
+revision = ${repr(up_revision)}
+down_revision = ${repr(down_revision)}
+branch_labels = ${repr(branch_labels)}
+depends_on = ${repr(depends_on)}
+
+
+def upgrade():
+ ${upgrades if upgrades else "pass"}
+
+
+def downgrade():
+ ${downgrades if downgrades else "pass"}
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/versions/2a07b543335e_add_new_syncer_table.py b/apps/cic-eth/cic_eth/db/migrations/default/versions/2a07b543335e_add_new_syncer_table.py
new file mode 100644
index 00000000..30ddb96f
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/versions/2a07b543335e_add_new_syncer_table.py
@@ -0,0 +1,35 @@
+"""Add new syncer table
+
+Revision ID: 2a07b543335e
+Revises: a2e2aab8f331
+Create Date: 2020-12-27 09:35:44.017981
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '2a07b543335e'
+down_revision = 'a2e2aab8f331'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'blockchain_sync',
+ sa.Column('id', sa.Integer, primary_key=True),
+ sa.Column('blockchain', sa.String, nullable=False),
+ sa.Column('block_start', sa.Integer, nullable=False, default=0),
+ sa.Column('tx_start', sa.Integer, nullable=False, default=0),
+ sa.Column('block_cursor', sa.Integer, nullable=False, default=0),
+ sa.Column('tx_cursor', sa.Integer, nullable=False, default=0),
+ sa.Column('block_target', sa.Integer, nullable=True),
+ sa.Column('date_created', sa.DateTime, nullable=False),
+ sa.Column('date_updated', sa.DateTime),
+ )
+
+
+def downgrade():
+ op.drop_table('blockchain_sync')
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/versions/49b348246d70_add_nonce_index.py b/apps/cic-eth/cic_eth/db/migrations/default/versions/49b348246d70_add_nonce_index.py
new file mode 100644
index 00000000..3abee1b6
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/versions/49b348246d70_add_nonce_index.py
@@ -0,0 +1,29 @@
+"""Add nonce index
+
+Revision ID: 49b348246d70
+Revises: 52c7c59cd0b1
+Create Date: 2020-12-19 09:45:36.186446
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '49b348246d70'
+down_revision = '52c7c59cd0b1'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'nonce',
+ sa.Column('id', sa.Integer, primary_key=True),
+ sa.Column('address_hex', sa.String(42), nullable=False, unique=True),
+ sa.Column('nonce', sa.Integer, nullable=False),
+ )
+
+
+def downgrade():
+ op.drop_table('nonce')
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/versions/52c7c59cd0b1_add_account_roles.py b/apps/cic-eth/cic_eth/db/migrations/default/versions/52c7c59cd0b1_add_account_roles.py
new file mode 100644
index 00000000..7aa74059
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/versions/52c7c59cd0b1_add_account_roles.py
@@ -0,0 +1,31 @@
+"""Add account roles
+
+Revision ID: 52c7c59cd0b1
+Revises: 9c4bd7491015
+Create Date: 2020-12-19 07:21:38.249237
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '52c7c59cd0b1'
+down_revision = '9c4bd7491015'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'account_role',
+ sa.Column('id', sa.Integer, primary_key=True),
+ sa.Column('tag', sa.Text, nullable=False, unique=True),
+ sa.Column('address_hex', sa.String(42), nullable=False),
+ )
+ pass
+
+
+def downgrade():
+ op.drop_table('account_role')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/versions/6ac7a1dadc46_add_otx_state_log.py b/apps/cic-eth/cic_eth/db/migrations/default/versions/6ac7a1dadc46_add_otx_state_log.py
new file mode 100644
index 00000000..f15834d9
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/versions/6ac7a1dadc46_add_otx_state_log.py
@@ -0,0 +1,30 @@
+"""Add otx state log
+
+Revision ID: 6ac7a1dadc46
+Revises: 89e1e9baa53c
+Create Date: 2021-01-30 13:59:49.022373
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '6ac7a1dadc46'
+down_revision = '89e1e9baa53c'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'otx_state_log',
+ sa.Column('id', sa.Integer, primary_key=True),
+ sa.Column('otx_id', sa.Integer, sa.ForeignKey('otx.id'), nullable=False),
+ sa.Column('date', sa.DateTime, nullable=False),
+ sa.Column('status', sa.Integer, nullable=False),
+ )
+
+
+def downgrade():
+ op.drop_table('otx_state_log')
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/versions/71708e943dbd_add_attempts_and_version_log_for_otx.py b/apps/cic-eth/cic_eth/db/migrations/default/versions/71708e943dbd_add_attempts_and_version_log_for_otx.py
new file mode 100644
index 00000000..3be687eb
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/versions/71708e943dbd_add_attempts_and_version_log_for_otx.py
@@ -0,0 +1,31 @@
+"""Add attempts and version log for otx
+
+Revision ID: 71708e943dbd
+Revises: 7e8d7626e38f
+Create Date: 2020-09-26 14:41:19.298651
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '71708e943dbd'
+down_revision = '7e8d7626e38f'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'otx_attempts',
+ sa.Column('id', sa.Integer, primary_key=True),
+ sa.Column('otx_id', sa.Integer, sa.ForeignKey('otx.id'), nullable=False),
+ sa.Column('date', sa.DateTime, nullable=False),
+ )
+ pass
+
+
+def downgrade():
+ op.drop_table('otx_attempts')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/versions/7cb65b893934_add_blocknumber_pointer.py b/apps/cic-eth/cic_eth/db/migrations/default/versions/7cb65b893934_add_blocknumber_pointer.py
new file mode 100644
index 00000000..74a97f83
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/versions/7cb65b893934_add_blocknumber_pointer.py
@@ -0,0 +1,31 @@
+"""add blocknumber pointer
+
+Revision ID: 7cb65b893934
+Revises: 8593fa1ca0f4
+Create Date: 2020-09-24 19:29:13.543648
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '7cb65b893934'
+down_revision = '8593fa1ca0f4'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'watcher_state',
+ sa.Column('block_number', sa.Integer)
+ )
+ conn = op.get_bind()
+ conn.execute('INSERT INTO watcher_state (block_number) VALUES (0);')
+ pass
+
+
+def downgrade():
+ op.drop_table('watcher_state')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/versions/7e8d7626e38f_add_block_sync.py b/apps/cic-eth/cic_eth/db/migrations/default/versions/7e8d7626e38f_add_block_sync.py
new file mode 100644
index 00000000..52f29a7b
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/versions/7e8d7626e38f_add_block_sync.py
@@ -0,0 +1,45 @@
+"""Add block sync
+
+Revision ID: 7e8d7626e38f
+Revises: cd2052be6db2
+Create Date: 2020-09-26 11:12:27.818524
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '7e8d7626e38f'
+down_revision = 'cd2052be6db2'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'block_sync',
+ sa.Column('id', sa.Integer, primary_key=True),
+ sa.Column('blockchain', sa.String, nullable=False, unique=True),
+ sa.Column('block_height_backlog', sa.Integer, nullable=False, default=0),
+ sa.Column('tx_height_backlog', sa.Integer, nullable=False, default=0),
+ sa.Column('block_height_session', sa.Integer, nullable=False, default=0),
+ sa.Column('tx_height_session', sa.Integer, nullable=False, default=0),
+ sa.Column('block_height_head', sa.Integer, nullable=False, default=0),
+ sa.Column('tx_height_head', sa.Integer, nullable=False, default=0),
+ sa.Column('date_created', sa.DateTime, nullable=False),
+ sa.Column('date_updated', sa.DateTime),
+ )
+ op.drop_table('watcher_state')
+ pass
+
+
+def downgrade():
+ op.drop_table('block_sync')
+ op.create_table(
+ 'watcher_state',
+ sa.Column('block_number', sa.Integer)
+ )
+ conn = op.get_bind()
+ conn.execute('INSERT INTO watcher_state (block_number) VALUES (0);')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/versions/8593fa1ca0f4_add_transaction_queue.py b/apps/cic-eth/cic_eth/db/migrations/default/versions/8593fa1ca0f4_add_transaction_queue.py
new file mode 100644
index 00000000..e9f9cf6a
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/versions/8593fa1ca0f4_add_transaction_queue.py
@@ -0,0 +1,35 @@
+"""Add transaction queue
+
+Revision ID: 8593fa1ca0f4
+Revises:
+Create Date: 2020-09-22 21:56:42.117047
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '8593fa1ca0f4'
+down_revision = None
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'otx',
+ sa.Column('id', sa.Integer, primary_key=True),
+ sa.Column('date_created', sa.DateTime, nullable=False),
+ sa.Column('nonce', sa.Integer, nullable=False),
+ sa.Column('tx_hash', sa.String(66), nullable=False),
+ sa.Column('signed_tx', sa.Text, nullable=False),
+ sa.Column('status', sa.Integer, nullable=False, default=-9),
+ sa.Column('block', sa.Integer),
+ )
+ op.create_index('idx_otx_tx', 'otx', ['tx_hash'], unique=True)
+
+
+def downgrade():
+ op.drop_index('idx_otx_tx')
+ op.drop_table('otx')
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/versions/89e1e9baa53c_add_account_lock.py b/apps/cic-eth/cic_eth/db/migrations/default/versions/89e1e9baa53c_add_account_lock.py
new file mode 100644
index 00000000..4b1c4401
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/versions/89e1e9baa53c_add_account_lock.py
@@ -0,0 +1,33 @@
+"""Add account lock
+
+Revision ID: 89e1e9baa53c
+Revises: 2a07b543335e
+Create Date: 2021-01-27 19:57:36.793882
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '89e1e9baa53c'
+down_revision = '2a07b543335e'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'lock',
+ sa.Column('id', sa.Integer, primary_key=True),
+ sa.Column("address", sa.String(42), nullable=True),
+ sa.Column('blockchain', sa.String),
+ sa.Column("flags", sa.BIGINT(), nullable=False, default=0),
+ sa.Column("date_created", sa.DateTime, nullable=False),
+ sa.Column("otx_id", sa.Integer, nullable=True),
+ )
+ op.create_index('idx_chain_address', 'lock', ['blockchain', 'address'], unique=True)
+
+def downgrade():
+ op.drop_index('idx_chain_address')
+ op.drop_table('lock')
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/versions/9c4bd7491015_rename_block_sync_table.py b/apps/cic-eth/cic_eth/db/migrations/default/versions/9c4bd7491015_rename_block_sync_table.py
new file mode 100644
index 00000000..f58721b2
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/versions/9c4bd7491015_rename_block_sync_table.py
@@ -0,0 +1,26 @@
+"""Rename block sync table
+
+Revision ID: 9c4bd7491015
+Revises: 9daa16518a91
+Create Date: 2020-10-15 23:45:56.306898
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '9c4bd7491015'
+down_revision = '9daa16518a91'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.rename_table('block_sync', 'otx_sync')
+ pass
+
+
+def downgrade():
+ op.rename_table('otx_sync', 'block_sync')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/versions/9daa16518a91_add_tx_sync_state.py b/apps/cic-eth/cic_eth/db/migrations/default/versions/9daa16518a91_add_tx_sync_state.py
new file mode 100644
index 00000000..2c6cc0fe
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/versions/9daa16518a91_add_tx_sync_state.py
@@ -0,0 +1,30 @@
+"""add tx sync state
+
+Revision ID: 9daa16518a91
+Revises: e3b5330ee71c
+Create Date: 2020-10-10 14:43:18.699276
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '9daa16518a91'
+down_revision = 'e3b5330ee71c'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+# op.create_table(
+# 'tx_sync',
+# sa.Column('tx', sa.String(66), nullable=False),
+# )
+# op.execute("INSERT INTO tx_sync VALUES('0x0000000000000000000000000000000000000000000000000000000000000000')")
+ pass
+
+
+def downgrade():
+# op.drop_table('tx_sync')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/versions/a2e2aab8f331_add_date_accessed_to_txcache.py b/apps/cic-eth/cic_eth/db/migrations/default/versions/a2e2aab8f331_add_date_accessed_to_txcache.py
new file mode 100644
index 00000000..f82f2615
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/versions/a2e2aab8f331_add_date_accessed_to_txcache.py
@@ -0,0 +1,34 @@
+"""Add date accessed to txcache
+
+Revision ID: a2e2aab8f331
+Revises: 49b348246d70
+Create Date: 2020-12-24 18:58:06.137812
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = 'a2e2aab8f331'
+down_revision = '49b348246d70'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.add_column(
+ 'tx_cache',
+ sa.Column(
+ 'date_checked',
+ sa.DateTime,
+ nullable=False
+ )
+ )
+ pass
+
+
+def downgrade():
+ # drop does not work withs qlite
+ #op.drop_column('tx_cache', 'date_checked')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/versions/cd2052be6db2_convert_tx_index.py b/apps/cic-eth/cic_eth/db/migrations/default/versions/cd2052be6db2_convert_tx_index.py
new file mode 100644
index 00000000..5b59d734
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/versions/cd2052be6db2_convert_tx_index.py
@@ -0,0 +1,34 @@
+"""convert tx index
+
+Revision ID: cd2052be6db2
+Revises: 7cb65b893934
+Create Date: 2020-09-24 21:20:51.580500
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = 'cd2052be6db2'
+down_revision = '7cb65b893934'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'tx_convert_transfer',
+ sa.Column('id', sa.Integer, primary_key=True),
+ #sa.Column('approve_tx_hash', sa.String(66), nullable=False, unique=True),
+ sa.Column('convert_tx_hash', sa.String(66), nullable=False, unique=True),
+ sa.Column('transfer_tx_hash', sa.String(66), unique=True),
+# sa.Column('holder_address', sa.String(42), nullable=False),
+ sa.Column('recipient_address', sa.String(42), nullable=False),
+ )
+ op.create_index('idx_tx_convert_address', 'tx_convert_transfer', ['recipient_address'])
+
+
+def downgrade():
+ op.drop_index('idx_tx_convert_address')
+ op.drop_table('tx_convert_transfer')
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/versions/df19f4e69676_add_tx_track.py b/apps/cic-eth/cic_eth/db/migrations/default/versions/df19f4e69676_add_tx_track.py
new file mode 100644
index 00000000..2c1ea138
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/versions/df19f4e69676_add_tx_track.py
@@ -0,0 +1,31 @@
+"""Add tx tracker record
+
+Revision ID: df19f4e69676
+Revises: 71708e943dbd
+Create Date: 2020-10-09 23:31:44.563498
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+# revision identifiers, used by Alembic.
+revision = 'df19f4e69676'
+down_revision = '71708e943dbd'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+# op.create_table(
+# 'tx',
+# sa.Column('id', sa.Integer, primary_key=True),
+# sa.Column('date_added', sa.DateTime, nullable=False),
+# sa.Column('tx_hash', sa.String(66), nullable=False, unique=True),
+# sa.Column('success', sa.Boolean(), nullable=False),
+# )
+ pass
+
+
+def downgrade():
+# op.drop_table('tx')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/migrations/default/versions/e3b5330ee71c_.py b/apps/cic-eth/cic_eth/db/migrations/default/versions/e3b5330ee71c_.py
new file mode 100644
index 00000000..37cb3b81
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/default/versions/e3b5330ee71c_.py
@@ -0,0 +1,38 @@
+"""Add cached values for tx
+
+Revision ID: e3b5330ee71c
+Revises: df19f4e69676
+Create Date: 2020-10-10 00:17:07.094893
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = 'e3b5330ee71c'
+down_revision = 'df19f4e69676'
+branch_labels = None
+depends_on = None
+
+def upgrade():
+ op.create_table(
+ 'tx_cache',
+ sa.Column('id', sa.Integer, primary_key=True),
+# sa.Column('tx_id', sa.Integer, sa.ForeignKey('tx.id'), nullable=True),
+ sa.Column('otx_id', sa.Integer, sa.ForeignKey('otx.id'), nullable=True),
+ sa.Column('date_created', sa.DateTime, nullable=False),
+ sa.Column('date_updated', sa.DateTime, nullable=False),
+ sa.Column('source_token_address', sa.String(42), nullable=False),
+ sa.Column('destination_token_address', sa.String(42), nullable=False),
+ sa.Column('sender', sa.String(42), nullable=False),
+ sa.Column('recipient', sa.String(42), nullable=False),
+ sa.Column('from_value', sa.String(), nullable=False),
+ sa.Column('to_value', sa.String(), nullable=True),
+ sa.Column('block_number', sa.BIGINT(), nullable=True),
+ sa.Column('tx_index', sa.Integer, nullable=True),
+ )
+
+def downgrade():
+ op.drop_table('tx_cache')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/alembic.ini b/apps/cic-eth/cic_eth/db/migrations/postgresql/alembic.ini
new file mode 100644
index 00000000..1555f68c
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/alembic.ini
@@ -0,0 +1,85 @@
+# A generic, single database configuration.
+
+[alembic]
+# path to migration scripts
+script_location = .
+
+# template used to generate migration files
+# file_template = %%(rev)s_%%(slug)s
+
+# timezone to use when rendering the date
+# within the migration file as well as the filename.
+# string value is passed to dateutil.tz.gettz()
+# leave blank for localtime
+# timezone =
+
+# max length of characters to apply to the
+# "slug" field
+# truncate_slug_length = 40
+
+# set to 'true' to run the environment during
+# the 'revision' command, regardless of autogenerate
+# revision_environment = false
+
+# set to 'true' to allow .pyc and .pyo files without
+# a source .py file to be detected as revisions in the
+# versions/ directory
+# sourceless = false
+
+# version location specification; this defaults
+# to migrations/versions. When using multiple version
+# directories, initial revisions must be specified with --version-path
+# version_locations = %(here)s/bar %(here)s/bat migrations/versions
+
+# the output encoding used when revision files
+# are written from script.py.mako
+# output_encoding = utf-8
+
+#sqlalchemy.url = driver://user:pass@localhost/dbname
+sqlalchemy.url = postgresql+psycopg2://postgres@localhost:5432/cic-eth
+
+[post_write_hooks]
+# post_write_hooks defines scripts or Python functions that are run
+# on newly generated revision scripts. See the documentation for further
+# detail and examples
+
+# format using "black" - use the console_scripts runner, against the "black" entrypoint
+# hooks=black
+# black.type=console_scripts
+# black.entrypoint=black
+# black.options=-l 79
+
+# Logging configuration
+[loggers]
+keys = root,sqlalchemy,alembic
+
+[handlers]
+keys = console
+
+[formatters]
+keys = generic
+
+[logger_root]
+level = WARN
+handlers = console
+qualname =
+
+[logger_sqlalchemy]
+level = WARN
+handlers =
+qualname = sqlalchemy.engine
+
+[logger_alembic]
+level = INFO
+handlers =
+qualname = alembic
+
+[handler_console]
+class = StreamHandler
+args = (sys.stderr,)
+level = NOTSET
+formatter = generic
+
+[formatter_generic]
+format = %(levelname)-5.5s [%(name)s] %(message)s
+datefmt = %H:%M:%S
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/env.py b/apps/cic-eth/cic_eth/db/migrations/postgresql/env.py
new file mode 100644
index 00000000..70518a2e
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/env.py
@@ -0,0 +1,77 @@
+from logging.config import fileConfig
+
+from sqlalchemy import engine_from_config
+from sqlalchemy import pool
+
+from alembic import context
+
+# this is the Alembic Config object, which provides
+# access to the values within the .ini file in use.
+config = context.config
+
+# Interpret the config file for Python logging.
+# This line sets up loggers basically.
+fileConfig(config.config_file_name)
+
+# add your model's MetaData object here
+# for 'autogenerate' support
+# from myapp import mymodel
+# target_metadata = mymodel.Base.metadata
+target_metadata = None
+
+# other values from the config, defined by the needs of env.py,
+# can be acquired:
+# my_important_option = config.get_main_option("my_important_option")
+# ... etc.
+
+
+def run_migrations_offline():
+ """Run migrations in 'offline' mode.
+
+ This configures the context with just a URL
+ and not an Engine, though an Engine is acceptable
+ here as well. By skipping the Engine creation
+ we don't even need a DBAPI to be available.
+
+ Calls to context.execute() here emit the given string to the
+ script output.
+
+ """
+ url = config.get_main_option("sqlalchemy.url")
+ context.configure(
+ url=url,
+ target_metadata=target_metadata,
+ literal_binds=True,
+ dialect_opts={"paramstyle": "named"},
+ )
+
+ with context.begin_transaction():
+ context.run_migrations()
+
+
+def run_migrations_online():
+ """Run migrations in 'online' mode.
+
+ In this scenario we need to create an Engine
+ and associate a connection with the context.
+
+ """
+ connectable = engine_from_config(
+ config.get_section(config.config_ini_section),
+ prefix="sqlalchemy.",
+ poolclass=pool.NullPool,
+ )
+
+ with connectable.connect() as connection:
+ context.configure(
+ connection=connection, target_metadata=target_metadata
+ )
+
+ with context.begin_transaction():
+ context.run_migrations()
+
+
+if context.is_offline_mode():
+ run_migrations_offline()
+else:
+ run_migrations_online()
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/script.py.mako b/apps/cic-eth/cic_eth/db/migrations/postgresql/script.py.mako
new file mode 100644
index 00000000..2c015630
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/script.py.mako
@@ -0,0 +1,24 @@
+"""${message}
+
+Revision ID: ${up_revision}
+Revises: ${down_revision | comma,n}
+Create Date: ${create_date}
+
+"""
+from alembic import op
+import sqlalchemy as sa
+${imports if imports else ""}
+
+# revision identifiers, used by Alembic.
+revision = ${repr(up_revision)}
+down_revision = ${repr(down_revision)}
+branch_labels = ${repr(branch_labels)}
+depends_on = ${repr(depends_on)}
+
+
+def upgrade():
+ ${upgrades if upgrades else "pass"}
+
+
+def downgrade():
+ ${downgrades if downgrades else "pass"}
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/2a07b543335e_add_new_syncer_table.py b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/2a07b543335e_add_new_syncer_table.py
new file mode 100644
index 00000000..30ddb96f
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/2a07b543335e_add_new_syncer_table.py
@@ -0,0 +1,35 @@
+"""Add new syncer table
+
+Revision ID: 2a07b543335e
+Revises: a2e2aab8f331
+Create Date: 2020-12-27 09:35:44.017981
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '2a07b543335e'
+down_revision = 'a2e2aab8f331'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'blockchain_sync',
+ sa.Column('id', sa.Integer, primary_key=True),
+ sa.Column('blockchain', sa.String, nullable=False),
+ sa.Column('block_start', sa.Integer, nullable=False, default=0),
+ sa.Column('tx_start', sa.Integer, nullable=False, default=0),
+ sa.Column('block_cursor', sa.Integer, nullable=False, default=0),
+ sa.Column('tx_cursor', sa.Integer, nullable=False, default=0),
+ sa.Column('block_target', sa.Integer, nullable=True),
+ sa.Column('date_created', sa.DateTime, nullable=False),
+ sa.Column('date_updated', sa.DateTime),
+ )
+
+
+def downgrade():
+ op.drop_table('blockchain_sync')
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/49b348246d70_add_nonce_index.py b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/49b348246d70_add_nonce_index.py
new file mode 100644
index 00000000..3abee1b6
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/49b348246d70_add_nonce_index.py
@@ -0,0 +1,29 @@
+"""Add nonce index
+
+Revision ID: 49b348246d70
+Revises: 52c7c59cd0b1
+Create Date: 2020-12-19 09:45:36.186446
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '49b348246d70'
+down_revision = '52c7c59cd0b1'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'nonce',
+ sa.Column('id', sa.Integer, primary_key=True),
+ sa.Column('address_hex', sa.String(42), nullable=False, unique=True),
+ sa.Column('nonce', sa.Integer, nullable=False),
+ )
+
+
+def downgrade():
+ op.drop_table('nonce')
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/52c7c59cd0b1_add_account_roles.py b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/52c7c59cd0b1_add_account_roles.py
new file mode 100644
index 00000000..7aa74059
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/52c7c59cd0b1_add_account_roles.py
@@ -0,0 +1,31 @@
+"""Add account roles
+
+Revision ID: 52c7c59cd0b1
+Revises: 9c4bd7491015
+Create Date: 2020-12-19 07:21:38.249237
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '52c7c59cd0b1'
+down_revision = '9c4bd7491015'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'account_role',
+ sa.Column('id', sa.Integer, primary_key=True),
+ sa.Column('tag', sa.Text, nullable=False, unique=True),
+ sa.Column('address_hex', sa.String(42), nullable=False),
+ )
+ pass
+
+
+def downgrade():
+ op.drop_table('account_role')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/6ac7a1dadc46_add_otx_state_log.py b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/6ac7a1dadc46_add_otx_state_log.py
new file mode 100644
index 00000000..f15834d9
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/6ac7a1dadc46_add_otx_state_log.py
@@ -0,0 +1,30 @@
+"""Add otx state log
+
+Revision ID: 6ac7a1dadc46
+Revises: 89e1e9baa53c
+Create Date: 2021-01-30 13:59:49.022373
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '6ac7a1dadc46'
+down_revision = '89e1e9baa53c'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'otx_state_log',
+ sa.Column('id', sa.Integer, primary_key=True),
+ sa.Column('otx_id', sa.Integer, sa.ForeignKey('otx.id'), nullable=False),
+ sa.Column('date', sa.DateTime, nullable=False),
+ sa.Column('status', sa.Integer, nullable=False),
+ )
+
+
+def downgrade():
+ op.drop_table('otx_state_log')
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/71708e943dbd_add_attempts_and_version_log_for_otx.py b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/71708e943dbd_add_attempts_and_version_log_for_otx.py
new file mode 100644
index 00000000..3be687eb
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/71708e943dbd_add_attempts_and_version_log_for_otx.py
@@ -0,0 +1,31 @@
+"""Add attempts and version log for otx
+
+Revision ID: 71708e943dbd
+Revises: 7e8d7626e38f
+Create Date: 2020-09-26 14:41:19.298651
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '71708e943dbd'
+down_revision = '7e8d7626e38f'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'otx_attempts',
+ sa.Column('id', sa.Integer, primary_key=True),
+ sa.Column('otx_id', sa.Integer, sa.ForeignKey('otx.id'), nullable=False),
+ sa.Column('date', sa.DateTime, nullable=False),
+ )
+ pass
+
+
+def downgrade():
+ op.drop_table('otx_attempts')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/7cb65b893934_add_blocknumber_pointer.py b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/7cb65b893934_add_blocknumber_pointer.py
new file mode 100644
index 00000000..74a97f83
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/7cb65b893934_add_blocknumber_pointer.py
@@ -0,0 +1,31 @@
+"""add blocknumber pointer
+
+Revision ID: 7cb65b893934
+Revises: 8593fa1ca0f4
+Create Date: 2020-09-24 19:29:13.543648
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '7cb65b893934'
+down_revision = '8593fa1ca0f4'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'watcher_state',
+ sa.Column('block_number', sa.Integer)
+ )
+ conn = op.get_bind()
+ conn.execute('INSERT INTO watcher_state (block_number) VALUES (0);')
+ pass
+
+
+def downgrade():
+ op.drop_table('watcher_state')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/7e8d7626e38f_add_block_sync.py b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/7e8d7626e38f_add_block_sync.py
new file mode 100644
index 00000000..6924fa26
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/7e8d7626e38f_add_block_sync.py
@@ -0,0 +1,42 @@
+"""Add block sync
+
+Revision ID: 7e8d7626e38f
+Revises: cd2052be6db2
+Create Date: 2020-09-26 11:12:27.818524
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '7e8d7626e38f'
+down_revision = 'cd2052be6db2'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'block_sync',
+ sa.Column('id', sa.Integer, primary_key=True),
+ sa.Column('blockchain', sa.String, nullable=False, unique=True),
+ sa.Column('height_backlog', sa.Integer, nullable=False, default=0),
+ sa.Column('height_session', sa.Integer, nullable=False, default=0),
+ sa.Column('height_head', sa.Integer, nullable=False, default=0),
+ sa.Column('date_created', sa.DateTime, nullable=False),
+ sa.Column('date_updated', sa.DateTime),
+ )
+ op.drop_table('watcher_state')
+ pass
+
+
+def downgrade():
+ op.drop_table('block_sync')
+ op.create_table(
+ 'watcher_state',
+ sa.Column('block_number', sa.Integer)
+ )
+ conn = op.get_bind()
+ conn.execute('INSERT INTO watcher_state (block_number) VALUES (0);')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/8593fa1ca0f4_add_transaction_queue.py b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/8593fa1ca0f4_add_transaction_queue.py
new file mode 100644
index 00000000..e9f9cf6a
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/8593fa1ca0f4_add_transaction_queue.py
@@ -0,0 +1,35 @@
+"""Add transaction queue
+
+Revision ID: 8593fa1ca0f4
+Revises:
+Create Date: 2020-09-22 21:56:42.117047
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '8593fa1ca0f4'
+down_revision = None
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'otx',
+ sa.Column('id', sa.Integer, primary_key=True),
+ sa.Column('date_created', sa.DateTime, nullable=False),
+ sa.Column('nonce', sa.Integer, nullable=False),
+ sa.Column('tx_hash', sa.String(66), nullable=False),
+ sa.Column('signed_tx', sa.Text, nullable=False),
+ sa.Column('status', sa.Integer, nullable=False, default=-9),
+ sa.Column('block', sa.Integer),
+ )
+ op.create_index('idx_otx_tx', 'otx', ['tx_hash'], unique=True)
+
+
+def downgrade():
+ op.drop_index('idx_otx_tx')
+ op.drop_table('otx')
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/89e1e9baa53c_add_account_lock.py b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/89e1e9baa53c_add_account_lock.py
new file mode 100644
index 00000000..05517fd2
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/89e1e9baa53c_add_account_lock.py
@@ -0,0 +1,32 @@
+"""Add account lock
+
+Revision ID: 89e1e9baa53c
+Revises: 2a07b543335e
+Create Date: 2021-01-27 19:57:36.793882
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '89e1e9baa53c'
+down_revision = '2a07b543335e'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'lock',
+ sa.Column('id', sa.Integer, primary_key=True),
+ sa.Column("address", sa.String(42), nullable=True),
+ sa.Column('blockchain', sa.String),
+ sa.Column("flags", sa.BIGINT(), nullable=False, default=0),
+ sa.Column("date_created", sa.DateTime, nullable=False),
+ )
+ op.create_index('idx_chain_address', 'lock', ['blockchain', 'address'], unique=True)
+
+def downgrade():
+ op.drop_index('idx_chain_address')
+ op.drop_table('lock')
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/9c4bd7491015_rename_block_sync_table.py b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/9c4bd7491015_rename_block_sync_table.py
new file mode 100644
index 00000000..f58721b2
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/9c4bd7491015_rename_block_sync_table.py
@@ -0,0 +1,26 @@
+"""Rename block sync table
+
+Revision ID: 9c4bd7491015
+Revises: 9daa16518a91
+Create Date: 2020-10-15 23:45:56.306898
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '9c4bd7491015'
+down_revision = '9daa16518a91'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.rename_table('block_sync', 'otx_sync')
+ pass
+
+
+def downgrade():
+ op.rename_table('otx_sync', 'block_sync')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/9daa16518a91_add_tx_sync_state.py b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/9daa16518a91_add_tx_sync_state.py
new file mode 100644
index 00000000..2c6cc0fe
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/9daa16518a91_add_tx_sync_state.py
@@ -0,0 +1,30 @@
+"""add tx sync state
+
+Revision ID: 9daa16518a91
+Revises: e3b5330ee71c
+Create Date: 2020-10-10 14:43:18.699276
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = '9daa16518a91'
+down_revision = 'e3b5330ee71c'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+# op.create_table(
+# 'tx_sync',
+# sa.Column('tx', sa.String(66), nullable=False),
+# )
+# op.execute("INSERT INTO tx_sync VALUES('0x0000000000000000000000000000000000000000000000000000000000000000')")
+ pass
+
+
+def downgrade():
+# op.drop_table('tx_sync')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/a2e2aab8f331_add_date_accessed_to_txcache.py b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/a2e2aab8f331_add_date_accessed_to_txcache.py
new file mode 100644
index 00000000..808a503c
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/a2e2aab8f331_add_date_accessed_to_txcache.py
@@ -0,0 +1,33 @@
+"""Add date accessed to txcache
+
+Revision ID: a2e2aab8f331
+Revises: 49b348246d70
+Create Date: 2020-12-24 18:58:06.137812
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = 'a2e2aab8f331'
+down_revision = '49b348246d70'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.add_column(
+ 'tx_cache',
+ sa.Column(
+ 'date_checked',
+ sa.DateTime,
+ nullable=False
+ )
+ )
+ pass
+
+
+def downgrade():
+ op.drop_column('tx_cache', 'date_checked')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/cd2052be6db2_convert_tx_index.py b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/cd2052be6db2_convert_tx_index.py
new file mode 100644
index 00000000..5b59d734
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/cd2052be6db2_convert_tx_index.py
@@ -0,0 +1,34 @@
+"""convert tx index
+
+Revision ID: cd2052be6db2
+Revises: 7cb65b893934
+Create Date: 2020-09-24 21:20:51.580500
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = 'cd2052be6db2'
+down_revision = '7cb65b893934'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+ op.create_table(
+ 'tx_convert_transfer',
+ sa.Column('id', sa.Integer, primary_key=True),
+ #sa.Column('approve_tx_hash', sa.String(66), nullable=False, unique=True),
+ sa.Column('convert_tx_hash', sa.String(66), nullable=False, unique=True),
+ sa.Column('transfer_tx_hash', sa.String(66), unique=True),
+# sa.Column('holder_address', sa.String(42), nullable=False),
+ sa.Column('recipient_address', sa.String(42), nullable=False),
+ )
+ op.create_index('idx_tx_convert_address', 'tx_convert_transfer', ['recipient_address'])
+
+
+def downgrade():
+ op.drop_index('idx_tx_convert_address')
+ op.drop_table('tx_convert_transfer')
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/df19f4e69676_add_tx_track.py b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/df19f4e69676_add_tx_track.py
new file mode 100644
index 00000000..2c1ea138
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/df19f4e69676_add_tx_track.py
@@ -0,0 +1,31 @@
+"""Add tx tracker record
+
+Revision ID: df19f4e69676
+Revises: 71708e943dbd
+Create Date: 2020-10-09 23:31:44.563498
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+# revision identifiers, used by Alembic.
+revision = 'df19f4e69676'
+down_revision = '71708e943dbd'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+# op.create_table(
+# 'tx',
+# sa.Column('id', sa.Integer, primary_key=True),
+# sa.Column('date_added', sa.DateTime, nullable=False),
+# sa.Column('tx_hash', sa.String(66), nullable=False, unique=True),
+# sa.Column('success', sa.Boolean(), nullable=False),
+# )
+ pass
+
+
+def downgrade():
+# op.drop_table('tx')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/e3b5330ee71c_.py b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/e3b5330ee71c_.py
new file mode 100644
index 00000000..ae53cf46
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/migrations/postgresql/versions/e3b5330ee71c_.py
@@ -0,0 +1,38 @@
+"""Add cached values for tx
+
+Revision ID: e3b5330ee71c
+Revises: df19f4e69676
+Create Date: 2020-10-10 00:17:07.094893
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = 'e3b5330ee71c'
+down_revision = 'df19f4e69676'
+branch_labels = None
+depends_on = None
+
+def upgrade():
+ op.create_table(
+ 'tx_cache',
+ sa.Column('id', sa.Integer, primary_key=True),
+# sa.Column('tx_id', sa.Integer, sa.ForeignKey('tx.id'), nullable=True),
+ sa.Column('otx_id', sa.Integer, sa.ForeignKey('otx.id'), nullable=True),
+ sa.Column('date_created', sa.DateTime, nullable=False),
+ sa.Column('date_updated', sa.DateTime, nullable=False),
+ sa.Column('source_token_address', sa.String(42), nullable=False),
+ sa.Column('destination_token_address', sa.String(42), nullable=False),
+ sa.Column('sender', sa.String(42), nullable=False),
+ sa.Column('recipient', sa.String(42), nullable=False),
+ sa.Column('from_value', sa.BIGINT(), nullable=False),
+ sa.Column('to_value', sa.BIGINT(), nullable=True),
+ sa.Column('block_number', sa.BIGINT(), nullable=True),
+ sa.Column('tx_index', sa.Integer, nullable=True),
+ )
+
+def downgrade():
+ op.drop_table('tx_cache')
+ pass
diff --git a/apps/cic-eth/cic_eth/db/models/base.py b/apps/cic-eth/cic_eth/db/models/base.py
new file mode 100644
index 00000000..153906af
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/models/base.py
@@ -0,0 +1,73 @@
+# third-party imports
+from sqlalchemy import Column, Integer
+from sqlalchemy.ext.declarative import declarative_base
+from sqlalchemy import create_engine
+from sqlalchemy.orm import sessionmaker
+
+Model = declarative_base(name='Model')
+
+
+class SessionBase(Model):
+ """The base object for all SQLAlchemy enabled models. All other models must extend this.
+ """
+ __abstract__ = True
+
+ id = Column(Integer, primary_key=True)
+
+ engine = None
+ """Database connection engine of the running aplication"""
+ sessionmaker = None
+ """Factory object responsible for creating sessions from the connection pool"""
+ transactional = True
+ """Whether the database backend supports query transactions. Should be explicitly set by initialization code"""
+ poolable = True
+ """Whether the database backend supports query transactions. Should be explicitly set by initialization code"""
+
+
+ @staticmethod
+ def create_session():
+ """Creates a new database session.
+ """
+ return SessionBase.sessionmaker()
+
+
+ @staticmethod
+ def _set_engine(engine):
+ """Sets the database engine static property
+ """
+ SessionBase.engine = engine
+ SessionBase.sessionmaker = sessionmaker(bind=SessionBase.engine)
+
+
+ @staticmethod
+ def connect(dsn, debug=False):
+ """Create new database connection engine and connect to database backend.
+
+ :param dsn: DSN string defining connection.
+ :type dsn: str
+ """
+ e = None
+ if SessionBase.poolable:
+ e = create_engine(
+ dsn,
+ max_overflow=50,
+ pool_pre_ping=True,
+ pool_size=20,
+ pool_recycle=10,
+ echo=debug,
+ )
+ else:
+ e = create_engine(
+ dsn,
+ echo=debug,
+ )
+
+ SessionBase._set_engine(e)
+
+
+ @staticmethod
+ def disconnect():
+ """Disconnect from database and free resources.
+ """
+ SessionBase.engine.dispose()
+ SessionBase.engine = None
diff --git a/apps/cic-eth/cic_eth/db/models/convert.py b/apps/cic-eth/cic_eth/db/models/convert.py
new file mode 100644
index 00000000..00956996
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/models/convert.py
@@ -0,0 +1,55 @@
+# third-party imports
+from sqlalchemy import Column, Enum, String, Integer
+from sqlalchemy.ext.hybrid import hybrid_method
+
+# local imports
+from .base import SessionBase
+from ..error import UnknownConvertError
+
+
+class TxConvertTransfer(SessionBase):
+ """Table describing a transfer of funds after conversion has been successfully performed.
+
+ :param convert_tx_hash: Transaction hash of convert transaction
+ :type convert_tx_hash: str, 0x-hex
+ :param recipient_address: Ethereum address of recipient of resulting token balance of conversion
+ :type recipient_address: str, 0x-hex
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ """
+ __tablename__ = 'tx_convert_transfer'
+
+ #approve_tx_hash = Column(String(66))
+ convert_tx_hash = Column(String(66))
+ transfer_tx_hash = Column(String(66))
+ recipient_address = Column(String(42))
+
+
+ @hybrid_method
+ def transfer(self, transfer_tx_hash):
+ """Persists transaction hash of performed transfer. Setting this ends the lifetime of this record.
+ """
+ self.transfer_tx_hash = transfer_tx_hash
+
+
+ @staticmethod
+ def get(convert_tx_hash):
+ """Retrieves a convert transfer record by conversion transaction hash in a separate session.
+
+ :param convert_tx_hash: Transaction hash of convert transaction
+ :type convert_tx_hash: str, 0x-hex
+ """
+ session = SessionBase.create_session()
+ q = session.query(TxConvertTransfer)
+ q = q.filter(TxConvertTransfer.convert_tx_hash==convert_tx_hash)
+ r = q.first()
+ session.close()
+ if r == None:
+ raise UnknownConvertError(convert_tx_hash)
+ return r
+
+
+ def __init__(self, convert_tx_hash, recipient_address, chain_str):
+ self.convert_tx_hash = convert_tx_hash
+ self.recipient_address = recipient_address
+ self.chain_str = chain_str
diff --git a/apps/cic-eth/cic_eth/db/models/lock.py b/apps/cic-eth/cic_eth/db/models/lock.py
new file mode 100644
index 00000000..dbd0fd64
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/models/lock.py
@@ -0,0 +1,190 @@
+# standard imports
+import datetime
+import logging
+
+# third-party imports
+from sqlalchemy import Column, String, Integer, DateTime, ForeignKey
+from cic_registry import zero_address
+
+# local imports
+from cic_eth.db.models.base import SessionBase
+from cic_eth.db.models.tx import TxCache
+from cic_eth.db.models.otx import Otx
+
+logg = logging.getLogger()
+
+
+class Lock(SessionBase):
+ """Deactivate functionality on a global or per-account basis
+
+ """
+
+ __tablename__ = "lock"
+
+ blockchain = Column(String)
+ address = Column(String, ForeignKey('tx_cache.sender'))
+ flags = Column(Integer)
+ date_created = Column(DateTime, default=datetime.datetime.utcnow)
+ otx_id = Column(Integer, ForeignKey('otx.id'))
+
+
+ def chain(self):
+ """Get chain the cached instance represents.
+ """
+ return self.blockchain
+
+
+ @staticmethod
+ def set(chain_str, flags, address=zero_address, session=None, tx_hash=None):
+ """Sets flags associated with the given address and chain.
+
+ If a flags entry does not exist it is created.
+
+ Does not validate the address against any other tables or components.
+
+ Valid flags can be found in cic_eth.db.enum.LockEnum.
+
+ :param chain_str: Chain spec string representation
+ :type str: str
+ :param flags: Flags to set
+ :type flags: number
+ :param address: Ethereum address
+ :type address: str, 0x-hex
+ :param session: Database session, if None a separate session will be used.
+ :type session: SQLAlchemy session
+ :returns: New flag state of entry
+ :rtype: number
+ """
+ localsession = session
+ if localsession == None:
+ localsession = SessionBase.create_session()
+
+ q = localsession.query(Lock)
+ #q = q.join(TxCache, isouter=True)
+ q = q.filter(Lock.address==address)
+ q = q.filter(Lock.blockchain==chain_str)
+ lock = q.first()
+
+ if lock == None:
+ lock = Lock()
+ lock.flags = 0
+ lock.address = address
+ lock.blockchain = chain_str
+ if tx_hash != None:
+ q = localsession.query(Otx)
+ q = q.filter(Otx.tx_hash==tx_hash)
+ otx = q.first()
+ if otx != None:
+ lock.otx_id = otx.id
+
+ lock.flags |= flags
+ r = lock.flags
+
+ localsession.add(lock)
+ localsession.commit()
+
+ if session == None:
+ localsession.close()
+
+ return r
+
+
+ @staticmethod
+ def reset(chain_str, flags, address=zero_address, session=None):
+ """Resets flags associated with the given address and chain.
+
+ If the resulting flags entry value is 0, the entry will be deleted.
+
+ Does not validate the address against any other tables or components.
+
+ Valid flags can be found in cic_eth.db.enum.LockEnum.
+
+ :param chain_str: Chain spec string representation
+ :type str: str
+ :param flags: Flags to set
+ :type flags: number
+ :param address: Ethereum address
+ :type address: str, 0x-hex
+ :param session: Database session, if None a separate session will be used.
+ :type session: SQLAlchemy session
+ :returns: New flag state of entry
+ :rtype: number
+ """
+ localsession = session
+ if localsession == None:
+ localsession = SessionBase.create_session()
+
+ q = localsession.query(Lock)
+ #q = q.join(TxCache, isouter=True)
+ q = q.filter(Lock.address==address)
+ q = q.filter(Lock.blockchain==chain_str)
+ lock = q.first()
+
+ r = 0
+ if lock != None:
+ lock.flags &= ~flags
+ if lock.flags == 0:
+ localsession.delete(lock)
+ else:
+ localsession.add(lock)
+ r = lock.flags
+ localsession.commit()
+
+ if session == None:
+ localsession.close()
+
+ return r
+
+
+ @staticmethod
+ def check(chain_str, flags, address=zero_address, session=None):
+ """Checks whether all given flags are set for given address and chain.
+
+ Does not validate the address against any other tables or components.
+
+ Valid flags can be found in cic_eth.db.enum.LockEnum.
+
+ :param chain_str: Chain spec string representation
+ :type str: str
+ :param flags: Flags to set
+ :type flags: number
+ :param address: Ethereum address
+ :type address: str, 0x-hex
+ :param session: Database session, if None a separate session will be used.
+ :type session: SQLAlchemy session
+ :returns: Returns the value of all flags matched
+ :rtype: number
+ """
+
+ localsession = session
+ if localsession == None:
+ localsession = SessionBase.create_session()
+
+ q = localsession.query(Lock)
+ #q = q.join(TxCache, isouter=True)
+ q = q.filter(Lock.address==address)
+ q = q.filter(Lock.blockchain==chain_str)
+ q = q.filter(Lock.flags.op('&')(flags)==flags)
+ lock = q.first()
+ if session == None:
+ localsession.close()
+
+ r = 0
+ if lock != None:
+ r = lock.flags & flags
+ return r
+
+
+ @staticmethod
+ def check_aggregate(chain_str, flags, address, session=None):
+ localsession = session
+ if localsession == None:
+ localsession = SessionBase.create_session()
+
+ r = Lock.check(chain_str, flags, session=localsession)
+ r |= Lock.check(chain_str, flags, address=address, session=localsession)
+
+ if session == None:
+ localsession.close()
+
+ return r
diff --git a/apps/cic-eth/cic_eth/db/models/nonce.py b/apps/cic-eth/cic_eth/db/models/nonce.py
new file mode 100644
index 00000000..2a7ad004
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/models/nonce.py
@@ -0,0 +1,86 @@
+# standard imports
+import logging
+
+# third-party imports
+from sqlalchemy import Column, String, Integer
+
+# local imports
+from .base import SessionBase
+
+logg = logging.getLogger()
+
+
+class Nonce(SessionBase):
+ """Provides thread-safe nonce increments.
+ """
+ __tablename__ = 'nonce'
+
+ nonce = Column(Integer)
+ address_hex = Column(String(42))
+
+
+ @staticmethod
+ def get(address, session=None):
+ localsession = session
+ if localsession == None:
+ localsession = SessionBase.create_session()
+
+
+ q = localsession.query(Nonce)
+ q = q.filter(Nonce.address_hex==address)
+ nonce = q.first()
+
+ nonce_value = None
+ if nonce != None:
+ nonce_value = nonce.nonce;
+
+ if session == None:
+ localsession.close()
+
+ return nonce_value
+
+
+ @staticmethod
+ def __get(conn, address):
+ r = conn.execute("SELECT nonce FROM nonce WHERE address_hex = '{}'".format(address))
+ nonce = r.fetchone()
+ if nonce == None:
+ return None
+ return nonce[0]
+
+
+ @staticmethod
+ def __set(conn, address, nonce):
+ conn.execute("UPDATE nonce set nonce = {} WHERE address_hex = '{}'".format(nonce, address))
+
+
+ @staticmethod
+ def next(address, initial_if_not_exists=0):
+ """Generate next nonce for the given address.
+
+ If there is no previous nonce record for the address, the nonce may be initialized to a specified value, or 0 if no value has been given.
+
+ :param address: Associate Ethereum address
+ :type address: str, 0x-hex
+ :param initial_if_not_exists: Initial nonce value to set if no record exists
+ :type initial_if_not_exists: number
+ :returns: Nonce
+ :rtype: number
+ """
+ conn = Nonce.engine.connect()
+ if Nonce.transactional:
+ conn.execute('BEGIN')
+ conn.execute('LOCK TABLE nonce IN SHARE ROW EXCLUSIVE MODE')
+ nonce = Nonce.__get(conn, address)
+ logg.debug('get nonce {} for address {}'.format(nonce, address))
+ if nonce == None:
+ nonce = initial_if_not_exists
+ conn.execute("INSERT INTO nonce (nonce, address_hex) VALUES ({}, '{}')".format(nonce, address))
+ logg.debug('setting default nonce to {} for address {}'.format(nonce, address))
+ Nonce.__set(conn, address, nonce+1)
+ if Nonce.transactional:
+ conn.execute('COMMIT')
+ conn.close()
+ return nonce
+
+
diff --git a/apps/cic-eth/cic_eth/db/models/otx.py b/apps/cic-eth/cic_eth/db/models/otx.py
new file mode 100644
index 00000000..43b938b6
--- /dev/null
+++ b/apps/cic-eth/cic_eth/db/models/otx.py
@@ -0,0 +1,455 @@
+# standard imports
+import datetime
+import logging
+
+# third-party imports
+from sqlalchemy import Column, Enum, String, Integer, DateTime, Text, or_, ForeignKey
+from sqlalchemy.ext.hybrid import hybrid_property, hybrid_method
+
+# local imports
+from .base import SessionBase
+from cic_eth.db.enum import StatusEnum
+from cic_eth.db.error import TxStateChangeError
+#from cic_eth.eth.util import address_hex_from_signed_tx
+
+logg = logging.getLogger()
+
+
+class OtxStateLog(SessionBase):
+
+ __tablename__ = 'otx_state_log'
+
+ date = Column(DateTime, default=datetime.datetime.utcnow)
+ status = Column(Integer)
+ otx_id = Column(Integer, ForeignKey('otx.id'))
+
+
+ def __init__(self, otx):
+ self.otx_id = otx.id
+ self.status = otx.status
+
+
+class Otx(SessionBase):
+ """Outgoing transactions with local origin.
+
+ :param nonce: Transaction nonce
+ :type nonce: number
+ :param address: Ethereum address of recipient - NOT IN USE, REMOVE
+ :type address: str
+ :param tx_hash: Tranasction hash
+ :type tx_hash: str, 0x-hex
+ :param signed_tx: Signed raw transaction data
+ :type signed_tx: str, 0x-hex
+ """
+ __tablename__ = 'otx'
+
+ tracing = False
+ """Whether to enable queue state tracing"""
+
+ nonce = Column(Integer)
+ date_created = Column(DateTime, default=datetime.datetime.utcnow)
+ tx_hash = Column(String(66))
+ signed_tx = Column(Text)
+ status = Column(Integer)
+ block = Column(Integer)
+
+
+ def __set_status(self, status, session=None):
+ localsession = session
+ if localsession == None:
+ localsession = SessionBase.create_session()
+
+ self.status = status
+ localsession.add(self)
+ localsession.flush()
+
+ if self.tracing:
+ self.__state_log(session=localsession)
+
+ if session==None:
+ localsession.commit()
+ localsession.close()
+
+
+ def set_block(self, block, session=None):
+ """Set block number transaction was mined in.
+
+ Only manipulates object, does not transaction or commit to backend.
+
+ :param block: Block number
+ :type block: number
+ :raises cic_eth.db.error.TxStateChangeError: State change represents a sequence of events that should not exist.
+ """
+ localsession = session
+ if localsession == None:
+ localsession = SessionBase.create_session()
+
+ if self.block != None:
+ raise TxStateChangeError('Attempted set block {} when block was already {}'.format(block, self.block))
+ self.block = block
+ localsession.add(self)
+ localsession.flush()
+
+ if session==None:
+ localsession.commit()
+ localsession.close()
+
+
+ def waitforgas(self, session=None):
+ """Marks transaction as suspended pending gas funding.
+
+ Only manipulates object, does not transaction or commit to backend.
+
+ :raises cic_eth.db.error.TxStateChangeError: State change represents a sequence of events that should not exist.
+ """
+ if self.status >= StatusEnum.SENT.value:
+ raise TxStateChangeError('WAITFORGAS cannot succeed final state, had {}'.format(StatusEnum(self.status).name))
+ self.__set_status(StatusEnum.WAITFORGAS, session)
+
+
+ def fubar(self, session=None):
+ """Marks transaction as "fubar." Any transaction marked this way is an anomaly and may be a symptom of a serious problem.
+
+ Only manipulates object, does not transaction or commit to backend.
+ """
+ self.__set_status(StatusEnum.FUBAR, session)
+
+
+ def reject(self, session=None):
+ """Marks transaction as "rejected," which means the node rejected sending the transaction to the network. The nonce has not been spent, and the transaction should be replaced.
+
+ Only manipulates object, does not transaction or commit to backend.
+ """
+ if self.status >= StatusEnum.SENT.value:
+ raise TxStateChangeError('REJECTED cannot succeed SENT or final state, had {}'.format(StatusEnum(self.status).name))
+ self.__set_status(StatusEnum.REJECTED, session)
+
+
+ def override(self, session=None):
+ """Marks transaction as manually overridden.
+
+ Only manipulates object, does not transaction or commit to backend.
+ """
+ if self.status >= StatusEnum.SENT.value:
+ raise TxStateChangeError('OVERRIDDEN cannot succeed SENT or final state, had {}'.format(StatusEnum(self.status).name))
+ self.__set_status(StatusEnum.OVERRIDDEN, session)
+
+
+ def retry(self, session=None):
+ """Marks transaction as ready to retry after a timeout following a sendfail or a completed gas funding.
+
+ Only manipulates object, does not transaction or commit to backend.
+
+ :raises cic_eth.db.error.TxStateChangeError: State change represents a sequence of events that should not exist.
+ """
+ if self.status != StatusEnum.SENT.value and self.status != StatusEnum.SENDFAIL.value:
+ raise TxStateChangeError('RETRY must follow SENT or SENDFAIL, but had {}'.format(StatusEnum(self.status).name))
+ self.__set_status(StatusEnum.RETRY, session)
+
+
+ def readysend(self, session=None):
+ """Marks transaction as ready for initial send attempt.
+
+ Only manipulates object, does not transaction or commit to backend.
+
+ :raises cic_eth.db.error.TxStateChangeError: State change represents a sequence of events that should not exist.
+ """
+ if self.status != StatusEnum.PENDING.value and self.status != StatusEnum.WAITFORGAS.value:
+ raise TxStateChangeError('READYSEND must follow PENDING or WAITFORGAS, but had {}'.format(StatusEnum(self.status).name))
+ self.__set_status(StatusEnum.READYSEND, session)
+
+
+ def sent(self, session=None):
+ """Marks transaction as having been sent to network.
+
+ Only manipulates object, does not transaction or commit to backend.
+
+ :raises cic_eth.db.error.TxStateChangeError: State change represents a sequence of events that should not exist.
+ """
+ if self.status > StatusEnum.SENT:
+ raise TxStateChangeError('SENT after {}'.format(StatusEnum(self.status).name))
+ self.__set_status(StatusEnum.SENT, session)
+
+
+ def sendfail(self, session=None):
+ """Marks that an attempt to send the transaction to the network has failed.
+
+ Only manipulates object, does not transaction or commit to backend.
+
+ :raises cic_eth.db.error.TxStateChangeError: State change represents a sequence of events that should not exist.
+ """
+ if self.status not in [StatusEnum.PENDING, StatusEnum.SENT, StatusEnum.WAITFORGAS]:
+ raise TxStateChangeError('SENDFAIL must follow SENT or PENDING, but had {}'.format(StatusEnum(self.status).name))
+ self.__set_status(StatusEnum.SENDFAIL, session)
+
+
+ def minefail(self, block, session=None):
+ """Marks that transaction was mined but code execution did not succeed.
+
+ Only manipulates object, does not transaction or commit to backend.
+
+ :param block: Block number transaction was mined in.
+ :type block: number
+ :raises cic_eth.db.error.TxStateChangeError: State change represents a sequence of events that should not exist.
+ """
+ if block != None:
+ self.block = block
+ if self.status != StatusEnum.SENT:
+ logg.warning('REVERTED should follow SENT, but had {}'.format(StatusEnum(self.status).name))
+ #if self.status != StatusEnum.PENDING and self.status != StatusEnum.OBSOLETED and self.status != StatusEnum.SENT:
+ #if self.status > StatusEnum.SENT:
+ # raise TxStateChangeError('REVERTED must follow OBSOLETED, PENDING or SENT, but had {}'.format(StatusEnum(self.status).name))
+ self.__set_status(StatusEnum.REVERTED, session)
+
+
+ def cancel(self, confirmed=False, session=None):
+ """Marks that the transaction has been succeeded by a new transaction with same nonce.
+
+ If set to confirmed, the previous state must be OBSOLETED, and will transition to CANCELLED - a finalized state. Otherwise, the state must follow a non-finalized state, and will be set to OBSOLETED.
+
+ Only manipulates object, does not transaction or commit to backend.
+
+ :param confirmed: Whether transition is to a final state.
+ :type confirmed: bool
+ :raises cic_eth.db.error.TxStateChangeError: State change represents a sequence of events that should not exist.
+ """
+ if confirmed:
+ if self.status != StatusEnum.OBSOLETED:
+ logg.warning('CANCELLED must follow OBSOLETED, but had {}'.format(StatusEnum(self.status).name))
+ #raise TxStateChangeError('CANCELLED must follow OBSOLETED, but had {}'.format(StatusEnum(self.status).name))
+ self.__set_status(StatusEnum.CANCELLED, session)
+ elif self.status != StatusEnum.OBSOLETED:
+ if self.status > StatusEnum.SENT:
+ logg.warning('OBSOLETED must follow PENDING, SENDFAIL or SENT, but had {}'.format(StatusEnum(self.status).name))
+ #raise TxStateChangeError('OBSOLETED must follow PENDING, SENDFAIL or SENT, but had {}'.format(StatusEnum(self.status).name))
+ self.__set_status(StatusEnum.OBSOLETED, session)
+
+
+ def success(self, block, session=None):
+ """Marks that transaction was successfully mined.
+
+ Only manipulates object, does not transaction or commit to backend.
+
+ :param block: Block number transaction was mined in.
+ :type block: number
+ :raises cic_eth.db.error.TxStateChangeError: State change represents a sequence of events that should not exist.
+ """
+
+ if block != None:
+ self.block = block
+ if self.status != StatusEnum.SENT:
+ logg.error('SUCCESS should follow SENT, but had {}'.format(StatusEnum(self.status).name))
+ #raise TxStateChangeError('SUCCESS must follow SENT, but had {}'.format(StatusEnum(self.status).name))
+ self.__set_status(StatusEnum.SUCCESS, session)
+
+
+ @staticmethod
+ def get(status=0, limit=4096, status_exact=True):
+ """Returns outgoing transaction lists by status.
+
+ Status may either be matched exactly, or be an upper bound of the integer value of the status enum.
+
+ :param status: Status value to use in query
+ :type status: cic_eth.db.enum.StatusEnum
+ :param limit: Max results to return
+ :type limit: number
+ :param status_exact: Whether or not to perform exact status match
+ :type bool:
+ :returns: List of transaction hashes
+ :rtype: tuple, where first element is transaction hash
+ """
+ e = None
+ session = Otx.create_session()
+ if status_exact:
+ e = session.query(Otx.tx_hash).filter(Otx.status==status).order_by(Otx.date_created.asc()).limit(limit).all()
+ else:
+ e = session.query(Otx.tx_hash).filter(Otx.status<=status).order_by(Otx.date_created.asc()).limit(limit).all()
+ session.close()
+ return e
+
+
+ @staticmethod
+ def load(tx_hash):
+ """Retrieves the outgoing transaction record by transaction hash.
+
+ :param tx_hash: Transaction hash
+ :type tx_hash: str, 0x-hex
+ """
+ session = Otx.create_session()
+ q = session.query(Otx)
+ q = q.filter(Otx.tx_hash==tx_hash)
+ session.close()
+ return q.first()
+
+
+ @staticmethod
+ def account(account_address):
+ """Retrieves all transaction hashes for which the given Ethereum address is sender or recipient.
+
+ :param account_address: Ethereum address to use in query.
+ :type account_address: str, 0x-hex
+ :returns: Outgoing transactions
+ :rtype: tuple, where first element is transaction hash
+ """
+ session = Otx.create_session()
+ q = session.query(Otx.tx_hash)
+ q = q.join(TxCache)
+ q = q.filter(or_(TxCache.sender==account_address, TxCache.recipient==account_address))
+ txs = q.all()
+ session.close()
+ return list(txs)
+
+
+ def __state_log(self, session):
+ l = OtxStateLog(self)
+ session.add(l)
+
+
+ @staticmethod
+ def add(nonce, address, tx_hash, signed_tx, session=None):
+ localsession = session
+ if localsession == None:
+ localsession = SessionBase.create_session()
+
+ otx = Otx(nonce, address, tx_hash, signed_tx)
+ localsession.add(otx)
+ localsession.flush()
+ if otx.tracing:
+ otx.__state_log(session=localsession)
+ localsession.flush()
+
+ if session==None:
+ localsession.commit()
+ localsession.close()
+ return None
+
+ return otx
+
+
+ def __init__(self, nonce, address, tx_hash, signed_tx):
+ self.nonce = nonce
+ self.tx_hash = tx_hash
+ self.signed_tx = signed_tx
+ self.status = StatusEnum.PENDING
+ signed_tx_bytes = bytes.fromhex(signed_tx[2:])
+
+ # sender_address = address_hex_from_signed_tx(signed_tx_bytes)
+ # logg.debug('decoded tx {}'.format(sender_address))
+
+
+
+# TODO: Most of the methods on this object are obsolete, but it contains a static function for retrieving "expired" outgoing transactions that should be moved to Otx instead.
+class OtxSync(SessionBase):
+ """Obsolete
+ """
+ __tablename__ = 'otx_sync'
+
+ blockchain = Column(String)
+ block_height_backlog = Column(Integer)
+ tx_height_backlog = Column(Integer)
+ block_height_session = Column(Integer)
+ tx_height_session = Column(Integer)
+ block_height_head = Column(Integer)
+ tx_height_head = Column(Integer)
+ date_created = Column(DateTime, default=datetime.datetime.utcnow)
+ date_updated = Column(DateTime)
+
+
+ def backlog(self, block_height=None, tx_height=None):
+ #session = OtxSync.create_session()
+ if block_height != None:
+ if tx_height == None:
+ raise ValueError('tx height missing')
+ self.block_height_backlog = block_height
+ self.tx_height_backlog = tx_height
+ #session.add(self)
+ self.date_updated = datetime.datetime.utcnow()
+ #session.commit()
+ block_height = self.block_height_backlog
+ tx_height = self.tx_height_backlog
+ #session.close()
+ return (block_height, tx_height)
+
+
+ def session(self, block_height=None, tx_height=None):
+ #session = OtxSync.create_session()
+ if block_height != None:
+ if tx_height == None:
+ raise ValueError('tx height missing')
+ self.block_height_session = block_height
+ self.tx_height_session = tx_height
+ #session.add(self)
+ self.date_updated = datetime.datetime.utcnow()
+ #session.commit()
+ block_height = self.block_height_session
+ tx_height = self.tx_height_session
+ #session.close()
+ return (block_height, tx_height)
+
+
+ def head(self, block_height=None, tx_height=None):
+ #session = OtxSync.create_session()
+ if block_height != None:
+ if tx_height == None:
+ raise ValueError('tx height missing')
+ self.block_height_head = block_height
+ self.tx_height_head = tx_height
+ #session.add(self)
+ self.date_updated = datetime.datetime.utcnow()
+ #session.commit()
+ block_height = self.block_height_head
+ tx_height = self.tx_height_head
+ #session.close()
+ return (block_height, tx_height)
+
+
+ @hybrid_property
+ def synced(self):
+ #return self.block_height_session == self.block_height_backlog and self.tx_height_session == self.block_height_backlog
+ return self.block_height_session == self.block_height_backlog and self.tx_height_session == self.tx_height_backlog
+
+
+ @staticmethod
+ def load(blockchain_string, session):
+ q = session.query(OtxSync)
+ q = q.filter(OtxSync.blockchain==blockchain_string)
+ return q.first()
+
+
+ @staticmethod
+ def latest(nonce):
+ session = SessionBase.create_session()
+ otx = session.query(Otx).filter(Otx.nonce==nonce).order_by(Otx.created.desc()).first()
+ session.close()
+ return otx
+
+
+ @staticmethod
+ def get_expired(datetime_threshold):
+ session = SessionBase.create_session()
+ q = session.query(Otx)
+ q = q.filter(Otx.date_created
+
+"""
+# standard imports
+import os
+
+# local imports
+from .rpc import RpcClient
+
+registry_extra_identifiers = {
+ 'Faucet': '0x{:0<64s}'.format(b'Faucet'.hex()),
+ 'TransferApproval': '0x{:0<64s}'.format(b'TransferApproval'.hex()),
+ }
+
diff --git a/apps/cic-eth/cic_eth/eth/account.py b/apps/cic-eth/cic_eth/eth/account.py
new file mode 100644
index 00000000..01a9f6ef
--- /dev/null
+++ b/apps/cic-eth/cic_eth/eth/account.py
@@ -0,0 +1,365 @@
+# standard imports
+import logging
+
+# third-party imports
+import web3
+import celery
+from cic_registry import CICRegistry
+from cic_registry.chain import ChainSpec
+from erc20_single_shot_faucet import Faucet
+from cic_registry import zero_address
+
+# local import
+from cic_eth.eth import RpcClient
+from cic_eth.eth import registry_extra_identifiers
+from cic_eth.eth.task import sign_and_register_tx
+from cic_eth.eth.task import create_check_gas_and_send_task
+from cic_eth.eth.factory import TxFactory
+from cic_eth.db.models.nonce import Nonce
+from cic_eth.db.models.base import SessionBase
+from cic_eth.db.models.role import AccountRole
+from cic_eth.db.models.tx import TxCache
+from cic_eth.eth.util import unpack_signed_raw_tx
+from cic_eth.error import RoleMissingError
+
+#logg = logging.getLogger(__name__)
+logg = logging.getLogger()
+celery_app = celery.current_app
+
+
+class AccountTxFactory(TxFactory):
+ """Factory for creating account index contract transactions
+ """
+ def add(
+ self,
+ address,
+ chain_spec,
+ ):
+ """Register an Ethereum account address with the on-chain account registry
+
+ :param address: Ethereum account address to add
+ :type address: str, 0x-hex
+ :param chain_spec: Chain to build transaction for
+ :type chain_spec: cic_registry.chain.ChainSpec
+ :returns: Unsigned "AccountRegistry.add" transaction in standard Ethereum format
+ :rtype: dict
+ """
+
+ c = CICRegistry.get_contract(chain_spec, 'AccountRegistry')
+ f = c.function('add')
+ tx_add_buildable = f(
+ address,
+ )
+ gas = c.gas('add')
+ tx_add = tx_add_buildable.buildTransaction({
+ 'from': self.address,
+ 'gas': gas,
+ 'gasPrice': self.gas_price,
+ 'chainId': chain_spec.chain_id(),
+ 'nonce': self.next_nonce(),
+ 'value': 0,
+ })
+ return tx_add
+
+
+ def gift(
+ self,
+ address,
+ chain_spec,
+ ):
+ """Trigger the on-chain faucet to disburse tokens to the provided Ethereum account
+
+ :param address: Ethereum account address to gift to
+ :type address: str, 0x-hex
+ :param chain_spec: Chain to build transaction for
+ :type chain_spec: cic_registry.chain.ChainSpec
+ :returns: Unsigned "Faucet.giveTo" transaction in standard Ethereum format
+ :rtype: dict
+ """
+
+ c = CICRegistry.get_contract(chain_spec, 'Faucet')
+ f = c.function('giveTo')
+ tx_add_buildable = f(address)
+ gas = c.gas('add')
+ tx_add = tx_add_buildable.buildTransaction({
+ 'from': self.address,
+ 'gas': gas,
+ 'gasPrice': self.gas_price,
+ 'chainId': chain_spec.chain_id(),
+ 'nonce': self.next_nonce(),
+ 'value': 0,
+ })
+ return tx_add
+
+
+def unpack_register(data):
+ """Verifies that a transaction is an "AccountRegister.add" transaction, and extracts call parameters from it.
+
+ :param data: Raw input data from Ethereum transaction.
+ :type data: str, 0x-hex
+ :raises ValueError: Function signature does not match AccountRegister.add
+ :returns: Parsed parameters
+ :rtype: dict
+ """
+ f = data[2:10]
+ if f != '0a3b0a4f':
+ raise ValueError('Invalid account index register data ({})'.format(f))
+
+ d = data[10:]
+ return {
+ 'to': web3.Web3.toChecksumAddress('0x' + d[64-40:64]),
+ }
+
+
+def unpack_gift(data):
+ """Verifies that a transaction is a "Faucet.giveTo" transaction, and extracts call parameters from it.
+
+ :param data: Raw input data from Ethereum transaction.
+ :type data: str, 0x-hex
+ :raises ValueError: Function signature does not match AccountRegister.add
+ :returns: Parsed parameters
+ :rtype: dict
+ """
+ f = data[2:10]
+ if f != '63e4bff4':
+ raise ValueError('Invalid account index register data ({})'.format(f))
+
+ d = data[10:]
+ return {
+ 'to': web3.Web3.toChecksumAddress('0x' + d[64-40:64]),
+ }
+
+
+@celery_app.task()
+def create(password, chain_str):
+ """Creates and stores a new ethereum account in the keystore.
+
+ The password is passed on to the wallet backend, no encryption is performed in the task worker.
+
+ :param password: Password to encrypt private key with
+ :type password: str
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :returns: Ethereum address of newly created account
+ :rtype: str, 0x-hex
+ """
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ c = RpcClient(chain_spec)
+ a = c.w3.eth.personal.new_account(password)
+ logg.debug('created account {}'.format(a))
+
+ # Initialize nonce provider record for account
+ n = c.w3.eth.getTransactionCount(a, 'pending')
+ session = SessionBase.create_session()
+ o = session.query(Nonce).filter(Nonce.address_hex==a).first()
+ if o == None:
+ o = Nonce()
+ o.address_hex = a
+ o.nonce = n
+ session.add(o)
+ session.commit()
+ session.close()
+ return a
+
+
+@celery_app.task(bind=True, throws=(RoleMissingError,))
+def register(self, account_address, chain_str, writer_address=None):
+ """Creates a transaction to add the given address to the accounts index.
+
+ :param account_address: Ethereum address to add
+ :type account_address: str, 0x-hex
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :param writer_address: Specify address in keystore to sign transaction. Overrides local accounts role setting.
+ :type writer_address: str, 0x-hex
+ :raises RoleMissingError: Writer address not set and writer role not found.
+ :returns: The account_address input param
+ :rtype: str, 0x-hex
+ """
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+
+ if writer_address == None:
+ writer_address = AccountRole.get_address('ACCOUNTS_INDEX_WRITER')
+
+ if writer_address == zero_address:
+ raise RoleMissingError(account_address)
+
+
+ logg.debug('adding account address {} to index; writer {}'.format(account_address, writer_address))
+ queue = self.request.delivery_info['routing_key']
+
+ c = RpcClient(chain_spec, holder_address=writer_address)
+ txf = AccountTxFactory(writer_address, c)
+
+ tx_add = txf.add(account_address, chain_spec)
+ (tx_hash_hex, tx_signed_raw_hex) = sign_and_register_tx(tx_add, chain_str, queue, 'cic_eth.eth.account.cache_account_data')
+
+ gas_budget = tx_add['gas'] * tx_add['gasPrice']
+
+ logg.debug('register user tx {}'.format(tx_hash_hex))
+ s = create_check_gas_and_send_task(
+ [tx_signed_raw_hex],
+ chain_str,
+ writer_address,
+ gas_budget,
+ tx_hashes_hex=[tx_hash_hex],
+ queue=queue,
+ )
+ s.apply_async()
+ return account_address
+
+
+@celery_app.task(bind=True)
+def gift(self, account_address, chain_str):
+ """Creates a transaction to invoke the faucet contract for the given address.
+
+ :param account_address: Ethereum address to give to
+ :type account_address: str, 0x-hex
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :returns: Raw signed transaction
+ :rtype: list with transaction as only element
+ """
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+
+ logg.debug('gift account address {} to index'.format(account_address))
+ queue = self.request.delivery_info['routing_key']
+
+ c = RpcClient(chain_spec, holder_address=account_address)
+ txf = AccountTxFactory(account_address, c)
+
+ tx_add = txf.gift(account_address, chain_spec)
+ (tx_hash_hex, tx_signed_raw_hex) = sign_and_register_tx(tx_add, chain_str, queue, 'cic_eth.eth.account.cache_gift_data')
+
+ gas_budget = tx_add['gas'] * tx_add['gasPrice']
+
+ logg.debug('register user tx {}'.format(tx_hash_hex))
+ s = create_check_gas_and_send_task(
+ [tx_signed_raw_hex],
+ chain_str,
+ account_address,
+ gas_budget,
+ [tx_hash_hex],
+ queue=queue,
+ )
+ s.apply_async()
+ return [tx_signed_raw_hex]
+
+
+@celery_app.task(bind=True)
+def have(self, account, chain_str):
+ """Check whether the given account exists in keystore
+
+ :param account: Account to check
+ :type account: str, 0x-hex
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :returns: Account, or None if not exists
+ :rtype: Varies
+ """
+ c = RpcClient(account)
+ try:
+ c.w3.eth.sign(account, text='2a')
+ return account
+ except Exception as e:
+ logg.debug('cannot sign with {}: {}'.format(account, e))
+ return None
+
+
+@celery_app.task(bind=True)
+def role(self, account, chain_str):
+ """Return account role for address
+
+ :param account: Account to check
+ :type account: str, 0x-hex
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :returns: Account, or None if not exists
+ :rtype: Varies
+ """
+ return AccountRole.role_for(account)
+
+
+@celery_app.task()
+def cache_gift_data(
+ tx_hash_hex,
+ tx_signed_raw_hex,
+ chain_str,
+ ):
+ """Generates and commits transaction cache metadata for a Faucet.giveTo transaction
+
+ :param tx_hash_hex: Transaction hash
+ :type tx_hash_hex: str, 0x-hex
+ :param tx_signed_raw_hex: Raw signed transaction
+ :type tx_signed_raw_hex: str, 0x-hex
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :returns: Transaction hash and id of cache element in storage backend, respectively
+ :rtype: tuple
+ """
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ c = RpcClient(chain_spec)
+
+ tx_signed_raw_bytes = bytes.fromhex(tx_signed_raw_hex[2:])
+ tx = unpack_signed_raw_tx(tx_signed_raw_bytes, chain_spec.chain_id())
+ tx_data = unpack_gift(tx['data'])
+
+ tx_cache = TxCache(
+ tx_hash_hex,
+ tx['from'],
+ tx['to'],
+ zero_address,
+ zero_address,
+ 0,
+ 0,
+ )
+
+ session = SessionBase.create_session()
+ session.add(tx_cache)
+ session.commit()
+ cache_id = tx_cache.id
+ session.close()
+ return (tx_hash_hex, cache_id)
+
+
+@celery_app.task()
+def cache_account_data(
+ tx_hash_hex,
+ tx_signed_raw_hex,
+ chain_str,
+ ):
+ """Generates and commits transaction cache metadata for an AccountsIndex.add transaction
+
+ :param tx_hash_hex: Transaction hash
+ :type tx_hash_hex: str, 0x-hex
+ :param tx_signed_raw_hex: Raw signed transaction
+ :type tx_signed_raw_hex: str, 0x-hex
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :returns: Transaction hash and id of cache element in storage backend, respectively
+ :rtype: tuple
+ """
+
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ c = RpcClient(chain_spec)
+
+ tx_signed_raw_bytes = bytes.fromhex(tx_signed_raw_hex[2:])
+ tx = unpack_signed_raw_tx(tx_signed_raw_bytes, chain_spec.chain_id())
+ tx_data = unpack_register(tx['data'])
+
+ tx_cache = TxCache(
+ tx_hash_hex,
+ tx['from'],
+ tx['to'],
+ zero_address,
+ zero_address,
+ 0,
+ 0,
+ )
+
+ session = SessionBase.create_session()
+ session.add(tx_cache)
+ session.commit()
+ cache_id = tx_cache.id
+ session.close()
+ return (tx_hash_hex, cache_id)
diff --git a/apps/cic-eth/cic_eth/eth/bancor.py b/apps/cic-eth/cic_eth/eth/bancor.py
new file mode 100644
index 00000000..fdc01144
--- /dev/null
+++ b/apps/cic-eth/cic_eth/eth/bancor.py
@@ -0,0 +1,385 @@
+# standard imports
+import os
+import logging
+
+# third-party imports
+import celery
+import web3
+from cic_registry import CICRegistry
+from cic_registry.chain import ChainSpec
+
+# local imports
+from cic_eth.db import SessionBase
+from cic_eth.db.models.convert import TxConvertTransfer
+from cic_eth.db.models.otx import Otx
+from cic_eth.db.models.tx import TxCache
+from cic_eth.eth.task import sign_and_register_tx
+from cic_eth.eth.task import create_check_gas_and_send_task
+from cic_eth.eth.token import TokenTxFactory
+from cic_eth.eth.factory import TxFactory
+from cic_eth.eth.util import unpack_signed_raw_tx
+from cic_eth.eth.rpc import RpcClient
+
+celery_app = celery.current_app
+#logg = celery_app.log.get_default_logger()
+logg = logging.getLogger()
+
+contract_function_signatures = {
+ 'convert': 'f3898a97',
+ 'convert2': '569706eb',
+ }
+
+
+class BancorTxFactory(TxFactory):
+
+ """Factory for creating Bancor network transactions.
+ """
+ def convert(
+ self,
+ source_token_address,
+ destination_token_address,
+ reserve_address,
+ source_amount,
+ minimum_return,
+ chain_spec,
+ fee_beneficiary='0x0000000000000000000000000000000000000000',
+ fee_ppm=0,
+ ):
+ """Create a BancorNetwork "convert" transaction.
+
+ :param source_token_address: ERC20 contract address for token to convert from
+ :type source_token_address: str, 0x-hex
+ :param destination_token_address: ERC20 contract address for token to convert to
+ :type destination_token_address: str, 0x-hex
+ :param reserve_address: ERC20 contract address of Common reserve token
+ :type reserve_address: str, 0x-hex
+ :param source_amount: Amount of source tokens to convert
+ :type source_amount: int
+ :param minimum_return: Minimum amount of destination tokens to accept as result for conversion
+ :type source_amount: int
+ :return: Unsigned "convert" transaction in standard Ethereum format
+ :rtype: dict
+ """
+ network_contract = CICRegistry.get_contract(chain_spec, 'BancorNetwork')
+ network_gas = network_contract.gas('convert')
+ tx_convert_buildable = network_contract.contract.functions.convert2(
+ [
+ source_token_address,
+ source_token_address,
+ reserve_address,
+ destination_token_address,
+ destination_token_address,
+ ],
+ source_amount,
+ minimum_return,
+ fee_beneficiary,
+ fee_ppm,
+ )
+ tx_convert = tx_convert_buildable.buildTransaction({
+ 'from': self.address,
+ 'gas': network_gas,
+ 'gasPrice': self.gas_price,
+ 'chainId': chain_spec.chain_id(),
+ 'nonce': self.next_nonce(),
+ })
+ return tx_convert
+
+
+def unpack_convert(data):
+ f = data[2:10]
+ if f != contract_function_signatures['convert2']:
+ raise ValueError('Invalid convert data ({})'.format(f))
+
+ d = data[10:]
+ path = d[384:]
+ source = path[64-40:64]
+ destination = path[-40:]
+
+ amount = int(d[64:128], 16)
+ min_return = int(d[128:192], 16)
+ fee_recipient = d[192:256]
+ fee = int(d[256:320], 16)
+ return {
+ 'amount': amount,
+ 'min_return': min_return,
+ 'source_token': web3.Web3.toChecksumAddress('0x' + source),
+ 'destination_token': web3.Web3.toChecksumAddress('0x' + destination),
+ 'fee_recipient': fee_recipient,
+ 'fee': fee,
+ }
+
+
+
+# Kept for historical reference, it unpacks a convert call without fee parameters
+#def _unpack_convert_mint(data):
+# f = data[2:10]
+# if f != contract_function_signatures['convert2']:
+# raise ValueError('Invalid convert data ({})'.format(f))
+#
+# d = data[10:]
+# path = d[256:]
+# source = path[64-40:64]
+# destination = path[-40:]
+#
+# amount = int(d[64:128], 16)
+# min_return = int(d[128:192], 16)
+# return {
+# 'amount': amount,
+# 'min_return': min_return,
+# 'source_token': web3.Web3.toChecksumAddress('0x' + source),
+# 'destination_token': web3.Web3.toChecksumAddress('0x' + destination),
+# }
+
+
+@celery_app.task(bind=True)
+def convert_with_default_reserve(self, tokens, from_address, source_amount, minimum_return, to_address, chain_str):
+ """Performs a conversion between two liquid tokens using Bancor network.
+
+ :param tokens: Token pair, source and destination respectively
+ :type tokens: list of str, 0x-hex
+ :param from_address: Ethereum address of sender
+ :type from_address: str, 0x-hex
+ :param source_amount: Amount of source tokens to convert
+ :type source_amount: int
+ :param minimum_return: Minimum about of destination tokens to receive
+ :type minimum_return: int
+ """
+
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ queue = self.request.delivery_info['routing_key']
+
+ c = RpcClient(chain_spec, holder_address=from_address)
+
+ cr = CICRegistry.get_contract(chain_spec, 'BancorNetwork')
+ source_token = CICRegistry.get_address(chain_spec, tokens[0]['address'])
+ reserve_address = CICRegistry.get_contract(chain_spec, 'BNTToken', 'ERC20').address()
+
+ tx_factory = TokenTxFactory(from_address, c)
+
+ tx_approve_zero = tx_factory.approve(source_token.address(), cr.address(), 0, chain_spec)
+ (tx_approve_zero_hash_hex, tx_approve_zero_signed_hex) = sign_and_register_tx(tx_approve_zero, chain_str, queue, 'cic_eth.eth.token.otx_cache_approve')
+
+ tx_approve = tx_factory.approve(source_token.address(), cr.address(), source_amount, chain_spec)
+ (tx_approve_hash_hex, tx_approve_signed_hex) = sign_and_register_tx(tx_approve, chain_str, queue, 'cic_eth.eth.token.otx_cache_approve')
+
+ tx_factory = BancorTxFactory(from_address, c)
+ tx_convert = tx_factory.convert(
+ tokens[0]['address'],
+ tokens[1]['address'],
+ reserve_address,
+ source_amount,
+ minimum_return,
+ chain_spec,
+ )
+ (tx_convert_hash_hex, tx_convert_signed_hex) = sign_and_register_tx(tx_convert, chain_str, queue, 'cic_eth.eth.bancor.otx_cache_convert')
+
+ # TODO: consider moving save recipient to async task / chain it before the tx send
+ if to_address != None:
+ save_convert_recipient(tx_convert_hash_hex, to_address, chain_str)
+
+ s = create_check_gas_and_send_task(
+ [tx_approve_zero_signed_hex, tx_approve_signed_hex, tx_convert_signed_hex],
+ chain_str,
+ from_address,
+ tx_approve_zero['gasPrice'] * tx_approve_zero['gas'],
+ tx_hashes_hex=[tx_approve_hash_hex],
+ queue=queue,
+ )
+ s.apply_async()
+ return tx_convert_hash_hex
+
+
+#@celery_app.task()
+#def process_approval(tx_hash_hex):
+# t = session.query(TxConvertTransfer).query(TxConvertTransfer.approve_tx_hash==tx_hash_hex).first()
+# c = session.query(Otx).query(Otx.tx_hash==t.convert_tx_hash)
+# gas_limit = 8000000
+# gas_price = GasOracle.gas_price()
+#
+# # TODO: use celery group instead
+# s_queue = celery.signature(
+# 'cic_eth.queue.tx.create',
+# [
+# nonce,
+# c['address'], # TODO: check that this is in fact sender address
+# c['tx_hash'],
+# c['signed_tx'],
+# ]
+# )
+# s_queue.apply_async()
+#
+# s_check_gas = celery.signature(
+# 'cic_eth.eth.tx.check_gas',
+# [
+# c['address'],
+# [c['signed_tx']],
+# gas_limit * gas_price,
+# ]
+# )
+# s_send = celery.signature(
+# 'cic_eth.eth.tx.send',
+# [],
+# )
+#
+# s_set_sent = celery.signature(
+# 'cic_eth.queue.tx.set_sent_status',
+# [False],
+# )
+# s_send.link(s_set_sent)
+# s_check_gas.link(s_send)
+# s_check_gas.apply_async()
+# return tx_hash_hex
+
+
+
+@celery_app.task()
+def save_convert_recipient(convert_hash, recipient_address, chain_str):
+ """Registers the recipient target for a convert-and-transfer operation.
+
+ :param convert_hash: Transaction hash of convert operation
+ :type convert_hash: str, 0x-hex
+ :param recipient_address: Address of consequtive transfer recipient
+ :type recipient_address: str, 0x-hex
+ """
+ session = SessionBase.create_session()
+ t = TxConvertTransfer(convert_hash, recipient_address, chain_str)
+ session.add(t)
+ session.commit()
+ session.close()
+
+
+@celery_app.task()
+def save_convert_transfer(convert_hash, transfer_hash):
+ """Registers that the transfer part of a convert-and-transfer operation has been executed.
+
+ :param convert_hash: Transaction hash of convert operation
+ :type convert_hash: str, 0x-hex
+ :param convert_hash: Transaction hash of transfer operation
+ :type convert_hash: str, 0x-hex
+ :returns: transfer_hash,
+ :rtype: list, single str, 0x-hex
+ """
+ session = SessionBase.create_session()
+ t = TxConvertTransfer.get(convert_hash)
+ t.transfer(transfer_hash)
+ session.add(t)
+ session.commit()
+ session.close()
+ return [transfer_hash]
+
+
+# TODO: seems unused, consider removing
+@celery_app.task()
+def resolve_converters_by_tokens(tokens, chain_str):
+ """Return converters for a list of tokens.
+
+ :param tokens: Token addresses to look up
+ :type tokens: list of str, 0x-hex
+ :return: Addresses of matching converters
+ :rtype: list of str, 0x-hex
+ """
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ for t in tokens:
+ c = CICRegistry.get_contract(chain_spec, 'ConverterRegistry')
+ fn = c.function('getConvertersByAnchors')
+ try:
+ converters = fn([t['address']]).call()
+ except Exception as e:
+ raise e
+ t['converters'] = converters
+
+ return tokens
+
+
+@celery_app.task(bind=True)
+def transfer_converted(self, tokens, holder_address, receiver_address, value, tx_convert_hash_hex, chain_str):
+ """Execute the ERC20 transfer of a convert-and-transfer operation.
+
+ First argument is a list of tokens, to enable the task to be chained to the symbol to token address resolver function. However, it accepts only one token as argument.
+
+ :param tokens: Token addresses
+ :type tokens: list of str, 0x-hex
+ :param holder_address: Token holder address
+ :type holder_address: str, 0x-hex
+ :param holder_address: Token receiver address
+ :type holder_address: str, 0x-hex
+ :param value: Amount of token, in 'wei'
+ :type value: int
+ :raises TokenCountError: Either none or more then one tokens have been passed as tokens argument
+ :return: Transaction hash
+ :rtype: str, 0x-hex
+ """
+ # we only allow one token, one transfer
+ if len(tokens) != 1:
+ raise TokenCountError
+
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+
+ queue = self.request.delivery_info['routing_key']
+
+ c = RpcClient(chain_spec, holder_address=holder_address)
+
+ # get transaction parameters
+ gas_price = c.gas_price()
+ tx_factory = TokenTxFactory(holder_address, c)
+
+ token_address = tokens[0]['address']
+ tx_transfer = tx_factory.transfer(
+ token_address,
+ receiver_address,
+ value,
+ chain_spec,
+ )
+ (tx_transfer_hash_hex, tx_transfer_signed_hex) = sign_and_register_tx(tx_transfer, chain_str, queue, 'cic_eth.eth.token.otx_cache_transfer')
+
+ # send transaction
+ logg.info('transfer converted token {} from {} to {} value {} {}'.format(token_address, holder_address, receiver_address, value, tx_transfer_signed_hex))
+ s = create_check_gas_and_send_task(
+ [tx_transfer_signed_hex],
+ chain_str,
+ holder_address,
+ tx_transfer['gasPrice'] * tx_transfer['gas'],
+ None,
+ queue,
+ )
+ s_save = celery.signature(
+ 'cic_eth.eth.bancor.save_convert_transfer',
+ [
+ tx_convert_hash_hex,
+ tx_transfer_hash_hex,
+ ],
+ queue=queue,
+ )
+ s_save.link(s)
+ s_save.apply_async()
+ return tx_transfer_hash_hex
+
+
+@celery_app.task()
+def otx_cache_convert(
+ tx_hash_hex,
+ tx_signed_raw_hex,
+ chain_str,
+ ):
+
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ tx_signed_raw_bytes = bytes.fromhex(tx_signed_raw_hex[2:])
+ tx = unpack_signed_raw_tx(tx_signed_raw_bytes, chain_spec.chain_id())
+ tx_data = unpack_convert(tx['data'])
+ logg.debug('tx data {}'.format(tx_data))
+
+ session = TxCache.create_session()
+ tx_cache = TxCache(
+ tx_hash_hex,
+ tx['from'],
+ tx['from'],
+ tx_data['source_token'],
+ tx_data['destination_token'],
+ tx_data['amount'],
+ tx_data['amount'],
+ )
+ session.add(tx_cache)
+ session.commit()
+ session.close()
+ return tx_hash_hex
+
diff --git a/apps/cic-eth/cic_eth/eth/factory.py b/apps/cic-eth/cic_eth/eth/factory.py
new file mode 100644
index 00000000..fef8a025
--- /dev/null
+++ b/apps/cic-eth/cic_eth/eth/factory.py
@@ -0,0 +1,41 @@
+# standard imports
+import logging
+
+# local imports
+from cic_registry import CICRegistry
+from cic_eth.eth.nonce import NonceOracle
+from cic_eth.eth import RpcClient
+
+logg = logging.getLogger(__name__)
+
+
+class TxFactory:
+ """Base class for transaction factory classes.
+
+ :param from_address: Signer address to create transaction on behalf of
+ :type from_address: str, 0x-hex
+ :param rpc_client: RPC connection object to use to acquire account nonce if no record in nonce cache
+ :type rpc_client: cic_eth.eth.rpc.RpcClient
+ """
+
+ gas_price = 100
+ """Gas price, updated between batches"""
+
+
+ def __init__(self, from_address, rpc_client):
+ self.address = from_address
+
+ self.default_nonce = rpc_client.w3.eth.getTransactionCount(from_address, 'pending')
+ self.nonce_oracle = NonceOracle(from_address, self.default_nonce)
+
+ TxFactory.gas_price = rpc_client.gas_price()
+ logg.debug('txfactory instance address {} gas price'.format(self.address, self.gas_price))
+
+
+ def next_nonce(self):
+ """Returns the current cached nonce value, and increments it for next transaction.
+
+ :returns: Nonce
+ :rtype: number
+ """
+ return self.nonce_oracle.next()
diff --git a/apps/cic-eth/cic_eth/eth/gas.py b/apps/cic-eth/cic_eth/eth/gas.py
new file mode 100644
index 00000000..5bbd13d3
--- /dev/null
+++ b/apps/cic-eth/cic_eth/eth/gas.py
@@ -0,0 +1,71 @@
+# standard imports
+import logging
+
+# local imports
+from cic_eth.db.models.role import AccountRole
+from cic_eth.db.models.base import SessionBase
+
+logg = logging.getLogger()
+
+
+class GasOracle():
+ """Provides gas pricing for transactions.
+
+ :param w3: Web3 object
+ :type w3: web3.Web3
+ """
+
+ __safe_threshold_amount_value = 2000000000 * 60000 * 3
+ __refill_amount_value = __safe_threshold_amount_value * 5
+ default_gas_limit = 21000
+
+ def __init__(self, w3):
+ self.w3 = w3
+ self.gas_price_current = w3.eth.gas_price()
+
+
+ def safe_threshold_amount(self):
+ """The gas balance threshold under which a new gas refill transaction should be initiated.
+
+ :returns: Gas token amount
+ :rtype: number
+ """
+ g = GasOracle.__safe_threshold_amount_value
+ logg.warning('gas safe threshold is currently hardcoded to {}'.format(g))
+ return g
+
+
+ def refill_amount(self):
+ """The amount of gas tokens to send in a gas refill transaction.
+
+ :returns: Gas token amount
+ :rtype: number
+ """
+ g = GasOracle.__refill_amount_value
+ logg.warning('gas refill amount is currently hardcoded to {}'.format(g))
+ return g
+
+
+ def gas_provider(self):
+ """Gas provider address.
+
+ :returns: Etheerum account address
+ :rtype: str, 0x-hex
+ """
+ return AccountRole.get_address('GAS_GIFTER')
+
+
+ def gas_price(self, category='safe'):
+ """Get projected gas price to use for a transaction at the current moment.
+
+ When the category parameter is implemented, it can be used to control the priority of a transaction in the network.
+
+ :param category: Bid level category to return price for. Currently has no effect.
+ :type category: str
+ :returns: Gas price
+ :rtype: number
+ """
+ #logg.warning('gas price hardcoded to category "safe"')
+ #g = 100
+ #return g
+ return self.gas_price_current
diff --git a/apps/cic-eth/cic_eth/eth/nonce.py b/apps/cic-eth/cic_eth/eth/nonce.py
new file mode 100644
index 00000000..6e8e0a75
--- /dev/null
+++ b/apps/cic-eth/cic_eth/eth/nonce.py
@@ -0,0 +1,23 @@
+# local imports
+from cic_eth.db.models.nonce import Nonce
+
+class NonceOracle():
+ """Ensures atomic nonce increments for all transactions across all tasks and threads.
+
+ :param address: Address to generate nonces for
+ :type address: str, 0x-hex
+ :param default_nonce: Initial nonce value to use if no nonce cache entry already exists
+ :type default_nonce: number
+ """
+ def __init__(self, address, default_nonce):
+ self.address = address
+ self.default_nonce = default_nonce
+
+
+ def next(self):
+ """Get next unique nonce.
+
+ :returns: Nonce
+ :rtype: number
+ """
+ return Nonce.next(self.address, self.default_nonce)
diff --git a/apps/cic-eth/cic_eth/eth/request.py b/apps/cic-eth/cic_eth/eth/request.py
new file mode 100644
index 00000000..8f1c6b96
--- /dev/null
+++ b/apps/cic-eth/cic_eth/eth/request.py
@@ -0,0 +1,194 @@
+# standard imports
+import logging
+
+# third-party imports
+import web3
+import celery
+from erc20_approval_escrow import TransferApproval
+from cic_registry import CICRegistry
+from cic_registry.chain import ChainSpec
+
+# local imports
+from cic_eth.db.models.tx import TxCache
+from cic_eth.db.models.base import SessionBase
+from cic_eth.eth import RpcClient
+from cic_eth.eth.factory import TxFactory
+from cic_eth.eth.task import sign_and_register_tx
+from cic_eth.eth.util import unpack_signed_raw_tx
+from cic_eth.eth.task import create_check_gas_and_send_task
+from cic_eth.error import TokenCountError
+
+celery_app = celery.current_app
+logg = logging.getLogger()
+
+contract_function_signatures = {
+ 'request': 'b0addede',
+ }
+
+
+class TransferRequestTxFactory(TxFactory):
+ """Factory for creating Transfer request transactions using the TransferApproval contract backend
+ """
+ def request(
+ self,
+ token_address,
+ beneficiary_address,
+ amount,
+ chain_spec,
+ ):
+ """Create a new TransferApproval.request transaction
+
+ :param token_address: Token to create transfer request for
+ :type token_address: str, 0x-hex
+ :param beneficiary_address: Beneficiary of token transfer
+ :type beneficiary_address: str, 0x-hex
+ :param amount: Amount of tokens to transfer
+ :type amount: number
+ :param chain_spec: Chain spec
+ :type chain_spec: cic_registry.chain.ChainSpec
+ :returns: Transaction in standard Ethereum format
+ :rtype: dict
+ """
+ transfer_approval = CICRegistry.get_contract(chain_spec, 'TransferApproval', 'TransferAuthorization')
+ fn = transfer_approval.function('createRequest')
+ tx_approval_buildable = fn(beneficiary_address, token_address, amount)
+ transfer_approval_gas = transfer_approval.gas('createRequest')
+
+ tx_approval = tx_approval_buildable.buildTransaction({
+ 'from': self.address,
+ 'gas': transfer_approval_gas,
+ 'gasPrice': self.gas_price,
+ 'chainId': chain_spec.chain_id(),
+ 'nonce': self.next_nonce(),
+ })
+ return tx_approval
+
+
+def unpack_transfer_approval_request(data):
+ """Verifies that a transaction is an "TransferApproval.request" transaction, and extracts call parameters from it.
+
+ :param data: Raw input data from Ethereum transaction.
+ :type data: str, 0x-hex
+ :raises ValueError: Function signature does not match AccountRegister.add
+ :returns: Parsed parameters
+ :rtype: dict
+ """
+ f = data[2:10]
+ if f != contract_function_signatures['request']:
+ raise ValueError('Invalid transfer request data ({})'.format(f))
+
+ d = data[10:]
+ return {
+ 'to': web3.Web3.toChecksumAddress('0x' + d[64-40:64]),
+ 'token': web3.Web3.toChecksumAddress('0x' + d[128-40:128]),
+ 'amount': int(d[128:], 16)
+ }
+
+
+@celery_app.task(bind=True)
+def transfer_approval_request(self, tokens, holder_address, receiver_address, value, chain_str):
+ """Creates a new transfer approval
+
+ :param tokens: Token to generate transfer request for
+ :type tokens: list with single token spec as dict
+ :param holder_address: Address to generate transfer on behalf of
+ :type holder_address: str, 0x-hex
+ :param receiver_address: Address to transfser tokens to
+ :type receiver_address: str, 0x-hex
+ :param value: Amount of tokens to transfer
+ :type value: number
+ :param chain_spec: Chain spec string representation
+ :type chain_spec: str
+ :raises cic_eth.error.TokenCountError: More than one token in tokens argument
+ :returns: Raw signed transaction
+ :rtype: list with transaction as only element
+ """
+
+ if len(tokens) != 1:
+ raise TokenCountError
+
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+
+ queue = self.request.delivery_info['routing_key']
+
+ t = tokens[0]
+
+ c = RpcClient(holder_address)
+
+ txf = TransferRequestTxFactory(holder_address, c)
+
+ tx_transfer = txf.request(t['address'], receiver_address, value, chain_spec)
+ (tx_hash_hex, tx_signed_raw_hex) = sign_and_register_tx(tx_transfer, chain_str, queue, 'cic_eth.eth.request.otx_cache_transfer_approval_request')
+
+ gas_budget = tx_transfer['gas'] * tx_transfer['gasPrice']
+
+ s = create_check_gas_and_send_task(
+ [tx_signed_raw_hex],
+ chain_str,
+ holder_address,
+ gas_budget,
+ [tx_hash_hex],
+ queue,
+ )
+ s.apply_async()
+ return [tx_signed_raw_hex]
+
+
+@celery_app.task()
+def otx_cache_transfer_approval_request(
+ tx_hash_hex,
+ tx_signed_raw_hex,
+ chain_str,
+ ):
+ """Generates and commits transaction cache metadata for an TransferApproval.request transaction
+
+ :param tx_hash_hex: Transaction hash
+ :type tx_hash_hex: str, 0x-hex
+ :param tx_signed_raw_hex: Raw signed transaction
+ :type tx_signed_raw_hex: str, 0x-hex
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :returns: Transaction hash and id of cache element in storage backend, respectively
+ :rtype: tuple
+ """
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ tx_signed_raw_bytes = bytes.fromhex(tx_signed_raw_hex[2:])
+ tx = unpack_signed_raw_tx(tx_signed_raw_bytes, chain_spec.chain_id())
+ logg.debug('in otx acche transfer approval request')
+ (txc, cache_id) = cache_transfer_approval_request_data(tx_hash_hex, tx)
+ return txc
+
+
+@celery_app.task()
+def cache_transfer_approval_request_data(
+ tx_hash_hex,
+ tx,
+ ):
+ """Helper function for otx_cache_transfer_approval_request
+
+ :param tx_hash_hex: Transaction hash
+ :type tx_hash_hex: str, 0x-hex
+ :param tx: Signed raw transaction
+ :type tx: str, 0x-hex
+ :returns: Transaction hash and id of cache element in storage backend, respectively
+ :rtype: tuple
+ """
+ tx_data = unpack_transfer_approval_request(tx['data'])
+ logg.debug('tx approval request data {}'.format(tx_data))
+ logg.debug('tx approval request {}'.format(tx))
+
+ session = SessionBase.create_session()
+ tx_cache = TxCache(
+ tx_hash_hex,
+ tx['from'],
+ tx_data['to'],
+ tx_data['token'],
+ tx_data['token'],
+ tx_data['amount'],
+ tx_data['amount'],
+ )
+ session.add(tx_cache)
+ session.commit()
+ cache_id = tx_cache.id
+ session.close()
+ return (tx_hash_hex, cache_id)
diff --git a/apps/cic-eth/cic_eth/eth/rpc.py b/apps/cic-eth/cic_eth/eth/rpc.py
new file mode 100644
index 00000000..0d5486f3
--- /dev/null
+++ b/apps/cic-eth/cic_eth/eth/rpc.py
@@ -0,0 +1,39 @@
+# standard imports
+import logging
+
+# local imports
+from cic_eth.eth.gas import GasOracle
+
+logg = logging.getLogger()
+
+
+class RpcClient(GasOracle):
+ """RPC wrapper for web3 enabling gas calculation helpers and signer middleware.
+
+ :param chain_spec: Chain spec
+ :type chain_spec: cic_registry.chain.ChainSpec
+ :param holder_address: DEPRECATED Address of subject of the session.
+ :type holder_address: str, 0x-hex
+ """
+
+ signer_ipc_path = None
+ """Unix socket path to JSONRPC signer and keystore"""
+
+ web3_constructor = None
+ """Custom function to build a web3 object with middleware plugins"""
+
+
+ def __init__(self, chain_spec, holder_address=None):
+ (self.provider, w3) = RpcClient.web3_constructor()
+ super(RpcClient, self).__init__(w3)
+ self.chain_spec = chain_spec
+ if holder_address != None:
+ self.holder_address = holder_address
+ logg.info('gasprice {}'.format(self.gas_price()))
+
+
+ @staticmethod
+ def set_constructor(web3_constructor):
+ """Sets the constructor to use for building the web3 object.
+ """
+ RpcClient.web3_constructor = web3_constructor
diff --git a/apps/cic-eth/cic_eth/eth/task.py b/apps/cic-eth/cic_eth/eth/task.py
new file mode 100644
index 00000000..0aeb4371
--- /dev/null
+++ b/apps/cic-eth/cic_eth/eth/task.py
@@ -0,0 +1,136 @@
+# standard imports
+import logging
+
+# third-party imports
+import celery
+from cic_registry.chain import ChainSpec
+
+# local imports
+from cic_eth.eth import RpcClient
+from cic_eth.queue.tx import create as queue_create
+
+celery_app = celery.current_app
+logg = celery_app.log.get_default_logger()
+
+
+@celery_app.task()
+def sign_tx(tx, chain_str):
+ """Sign a single transaction against the given chain specification.
+
+ :param tx: Transaction in standard Ethereum format
+ :type tx: dict
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :returns: Transaction hash and raw signed transaction, respectively
+ :rtype: tuple
+ """
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ c = RpcClient(chain_spec)
+ tx_transfer_signed = c.w3.eth.sign_transaction(tx)
+ logg.debug('tx_transfer_signed {}'.format(tx_transfer_signed))
+ tx_hash = c.w3.keccak(hexstr=tx_transfer_signed['raw'])
+ tx_hash_hex = tx_hash.hex()
+ return (tx_hash_hex, tx_transfer_signed['raw'],)
+
+
+def sign_and_register_tx(tx, chain_str, queue, cache_task=None):
+ """Signs the provided transaction, and adds it to the transaction queue cache (with status PENDING).
+
+ :param tx: Standard ethereum transaction data
+ :type tx: dict
+ :param chain_str: Chain spec, string representation
+ :type chain_str: str
+ :param queue: Task queue
+ :type queue: str
+ :param cache_task: Cache task to call with signed transaction. If None, no task will be called.
+ :type cache_task: str
+ :returns: Tuple; Transaction hash, signed raw transaction data
+ :rtype: tuple
+ """
+ (tx_hash_hex, tx_signed_raw_hex) = sign_tx(tx, chain_str)
+
+ logg.debug('adding queue tx {}'.format(tx_hash_hex))
+
+# s = celery.signature(
+# 'cic_eth.queue.tx.create',
+# [
+# tx['nonce'],
+# tx['from'],
+# tx_hash_hex,
+# tx_signed_raw_hex,
+# chain_str,
+# ],
+# queue=queue,
+# )
+
+ # TODO: consider returning this as a signature that consequtive tasks can be linked to
+ queue_create(
+ tx['nonce'],
+ tx['from'],
+ tx_hash_hex,
+ tx_signed_raw_hex,
+ chain_str,
+ )
+
+ if cache_task != None:
+ logg.debug('adding cache task {} tx {}'.format(cache_task, tx_hash_hex))
+ s_cache = celery.signature(
+ cache_task,
+ [
+ tx_hash_hex,
+ tx_signed_raw_hex,
+ chain_str,
+ ],
+ queue=queue,
+ )
+ s_cache.apply_async()
+
+ return (tx_hash_hex, tx_signed_raw_hex,)
+
+
+# TODO: rename as we will not be sending task in the chain, this is the responsibility of the dispatcher
+def create_check_gas_and_send_task(tx_signed_raws_hex, chain_str, holder_address, gas, tx_hashes_hex=None, queue=None):
+ """Creates a celery task signature for a check_gas task that adds the task to the outgoing queue to be processed by the dispatcher.
+
+ If tx_hashes_hex is not spefified, a preceding task chained to check_gas must supply the transaction hashes as its return value.
+
+ :param tx_signed_raws_hex: Raw signed transaction data
+ :type tx_signed_raws_hex: list of str, 0x-hex
+ :param chain_str: Chain spec, string representation
+ :type chain_str: str
+ :param holder_address: Address sending the transactions
+ :type holder_address: str, 0x-hex
+ :param gas: Gas budget hint for transactions
+ :type gas: int
+ :param tx_hashes_hex: Transaction hashes
+ :type tx_hashes_hex: list of str, 0x-hex
+ :param queue: Task queue
+ :type queue: str
+ :returns: Signature of task chain
+ :rtype: celery.Signature
+ """
+ s_check_gas = None
+ if tx_hashes_hex != None:
+ s_check_gas = celery.signature(
+ 'cic_eth.eth.tx.check_gas',
+ [
+ tx_hashes_hex,
+ chain_str,
+ tx_signed_raws_hex,
+ holder_address,
+ gas,
+ ],
+ queue=queue,
+ )
+ else:
+ s_check_gas = celery.signature(
+ 'cic_eth.eth.tx.check_gas',
+ [
+ chain_str,
+ tx_signed_raws_hex,
+ holder_address,
+ gas,
+ ],
+ queue=queue,
+ )
+ return s_check_gas
diff --git a/apps/cic-eth/cic_eth/eth/token.py b/apps/cic-eth/cic_eth/eth/token.py
new file mode 100644
index 00000000..fac767e9
--- /dev/null
+++ b/apps/cic-eth/cic_eth/eth/token.py
@@ -0,0 +1,447 @@
+# standard imports
+import logging
+
+# third-party imports
+import celery
+import requests
+import web3
+from cic_registry import CICRegistry
+from cic_registry.chain import ChainSpec
+
+# platform imports
+from cic_eth.db.models.tx import TxCache
+from cic_eth.db.models.base import SessionBase
+from cic_eth.eth import RpcClient
+from cic_eth.error import TokenCountError, PermanentTxError, OutOfGasError, NotLocalTxError
+from cic_eth.eth.task import sign_and_register_tx
+from cic_eth.eth.task import create_check_gas_and_send_task
+from cic_eth.eth.factory import TxFactory
+from cic_eth.eth.util import unpack_signed_raw_tx
+
+celery_app = celery.current_app
+logg = logging.getLogger()
+
+# TODO: fetch from cic-contracts instead when implemented
+contract_function_signatures = {
+ 'transfer': 'a9059cbb',
+ 'approve': '095ea7b3',
+ 'transferfrom': '23b872dd',
+ }
+
+
+class TokenTxFactory(TxFactory):
+ """Factory for creating ERC20 token transactions.
+ """
+ def approve(
+ self,
+ token_address,
+ spender_address,
+ amount,
+ chain_spec,
+ ):
+ """Create an ERC20 "approve" transaction
+
+ :param token_address: ERC20 contract address
+ :type token_address: str, 0x-hex
+ :param spender_address: Address to approve spending for
+ :type spender_address: str, 0x-hex
+ :param amount: Amount of tokens to approve
+ :type amount: int
+ :param chain_spec: Chain spec
+ :type chain_spec: cic_registry.chain.ChainSpec
+ :returns: Unsigned "approve" transaction in standard Ethereum format
+ :rtype: dict
+ """
+ source_token = CICRegistry.get_address(chain_spec, token_address)
+ source_token_contract = source_token.contract
+ tx_approve_buildable = source_token_contract.functions.approve(
+ spender_address,
+ amount,
+ )
+ source_token_gas = source_token.gas('transfer')
+
+ tx_approve = tx_approve_buildable.buildTransaction({
+ 'from': self.address,
+ 'gas': source_token_gas,
+ 'gasPrice': self.gas_price,
+ 'chainId': chain_spec.chain_id(),
+ 'nonce': self.next_nonce(),
+ })
+ return tx_approve
+
+
+ def transfer(
+ self,
+ token_address,
+ receiver_address,
+ value,
+ chain_spec,
+ ):
+ """Create an ERC20 "transfer" transaction
+
+ :param token_address: ERC20 contract address
+ :type token_address: str, 0x-hex
+ :param receiver_address: Address to send tokens to
+ :type receiver_address: str, 0x-hex
+ :param amount: Amount of tokens to send
+ :type amount: int
+ :param chain_spec: Chain spec
+ :type chain_spec: cic_registry.chain.ChainSpec
+ :returns: Unsigned "transfer" transaction in standard Ethereum format
+ :rtype: dict
+ """
+ source_token = CICRegistry.get_address(chain_spec, token_address)
+ source_token_contract = source_token.contract
+ transfer_buildable = source_token_contract.functions.transfer(
+ receiver_address,
+ value,
+ )
+ source_token_gas = source_token.gas('transfer')
+
+ tx_transfer = transfer_buildable.buildTransaction(
+ {
+ 'from': self.address,
+ 'gas': source_token_gas,
+ 'gasPrice': self.gas_price,
+ 'chainId': chain_spec.chain_id(),
+ 'nonce': self.next_nonce(),
+ })
+ return tx_transfer
+
+
+def unpack_transfer(data):
+ """Verifies that a transaction is an "ERC20.transfer" transaction, and extracts call parameters from it.
+
+ :param data: Raw input data from Ethereum transaction.
+ :type data: str, 0x-hex
+ :raises ValueError: Function signature does not match AccountRegister.add
+ :returns: Parsed parameters
+ :rtype: dict
+ """
+ f = data[2:10]
+ if f != contract_function_signatures['transfer']:
+ raise ValueError('Invalid transfer data ({})'.format(f))
+
+ d = data[10:]
+ return {
+ 'to': web3.Web3.toChecksumAddress('0x' + d[64-40:64]),
+ 'amount': int(d[64:], 16)
+ }
+
+
+def unpack_transferfrom(data):
+ """Verifies that a transaction is an "ERC20.transferFrom" transaction, and extracts call parameters from it.
+
+ :param data: Raw input data from Ethereum transaction.
+ :type data: str, 0x-hex
+ :raises ValueError: Function signature does not match AccountRegister.add
+ :returns: Parsed parameters
+ :rtype: dict
+ """
+ f = data[2:10]
+ if f != contract_function_signatures['transferfrom']:
+ raise ValueError('Invalid transferFrom data ({})'.format(f))
+
+ d = data[10:]
+ return {
+ 'from': web3.Web3.toChecksumAddress('0x' + d[64-40:64]),
+ 'to': web3.Web3.toChecksumAddress('0x' + d[128-40:128]),
+ 'amount': int(d[128:], 16)
+ }
+
+
+def unpack_approve(data):
+ """Verifies that a transaction is an "ERC20.approve" transaction, and extracts call parameters from it.
+
+ :param data: Raw input data from Ethereum transaction.
+ :type data: str, 0x-hex
+ :raises ValueError: Function signature does not match AccountRegister.add
+ :returns: Parsed parameters
+ :rtype: dict
+ """
+ f = data[2:10]
+ if f != contract_function_signatures['approve']:
+ raise ValueError('Invalid approval data ({})'.format(f))
+
+ d = data[10:]
+ return {
+ 'to': web3.Web3.toChecksumAddress('0x' + d[64-40:64]),
+ 'amount': int(d[64:], 16)
+ }
+
+
+@celery_app.task()
+def balance(tokens, holder_address, chain_str):
+ """Return token balances for a list of tokens for given address
+
+ :param tokens: Token addresses
+ :type tokens: list of str, 0x-hex
+ :param holder_address: Token holder address
+ :type holder_address: str, 0x-hex
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :return: List of balances
+ :rtype: list of int
+ """
+ #abi = ContractRegistry.abi('ERC20Token')
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ balances = []
+ c = RpcClient(chain_spec)
+ for t in tokens:
+ #token = CICRegistry.get_address(t['address'])
+ #abi = token.abi()
+ #o = c.w3.eth.contract(abi=abi, address=t['address'])
+ o = CICRegistry.get_address(chain_spec, t['address']).contract
+ b = o.functions.balanceOf(holder_address).call()
+ logg.debug('balance {} for {}: {}'.format(t['address'], holder_address, b))
+ balances.append(b)
+ return b
+
+
+@celery_app.task(bind=True)
+def transfer(self, tokens, holder_address, receiver_address, value, chain_str):
+ """Transfer ERC20 tokens between addresses
+
+ First argument is a list of tokens, to enable the task to be chained to the symbol to token address resolver function. However, it accepts only one token as argument.
+
+ :raises TokenCountError: Either none or more then one tokens have been passed as tokens argument
+
+ :param tokens: Token addresses
+ :type tokens: list of str, 0x-hex
+ :param holder_address: Token holder address
+ :type holder_address: str, 0x-hex
+ :param receiver_address: Token receiver address
+ :type receiver_address: str, 0x-hex
+ :param value: Amount of token, in 'wei'
+ :type value: int
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :raises TokenCountError: More than one token is passed in tokens list
+ :return: Transaction hash for tranfer operation
+ :rtype: str, 0x-hex
+ """
+ # we only allow one token, one transfer
+ if len(tokens) != 1:
+ raise TokenCountError
+
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+
+ queue = self.request.delivery_info['routing_key']
+
+ # retrieve the token interface
+ t = tokens[0]
+
+ c = RpcClient(chain_spec, holder_address=holder_address)
+
+ txf = TokenTxFactory(holder_address, c)
+
+ tx_transfer = txf.transfer(t['address'], receiver_address, value, chain_spec)
+ (tx_hash_hex, tx_signed_raw_hex) = sign_and_register_tx(tx_transfer, chain_str, queue, cache_task='cic_eth.eth.token.otx_cache_transfer')
+
+ gas_budget = tx_transfer['gas'] * tx_transfer['gasPrice']
+
+ s = create_check_gas_and_send_task(
+ [tx_signed_raw_hex],
+ chain_str,
+ holder_address,
+ gas_budget,
+ [tx_hash_hex],
+ queue,
+ )
+ s.apply_async()
+ return tx_hash_hex
+
+
+@celery_app.task(bind=True)
+def approve(self, tokens, holder_address, spender_address, value, chain_str):
+ """Approve ERC20 transfer on behalf of holder address
+
+ First argument is a list of tokens, to enable the task to be chained to the symbol to token address resolver function. However, it accepts only one token as argument.
+
+ :raises TokenCountError: Either none or more then one tokens have been passed as tokens argument
+
+ :param tokens: Token addresses
+ :type tokens: list of str, 0x-hex
+ :param holder_address: Token holder address
+ :type holder_address: str, 0x-hex
+ :param receiver_address: Token receiver address
+ :type receiver_address: str, 0x-hex
+ :param value: Amount of token, in 'wei'
+ :type value: int
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :raises TokenCountError: More than one token is passed in tokens list
+ :return: Transaction hash for tranfer operation
+ :rtype: str, 0x-hex
+ """
+ # we only allow one token, one transfer
+ if len(tokens) != 1:
+ raise TokenCountError
+
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+
+ queue = self.request.delivery_info['routing_key']
+
+ # retrieve the token interface
+ t = tokens[0]
+
+ c = RpcClient(chain_spec, holder_address=holder_address)
+
+ txf = TokenTxFactory(holder_address, c)
+
+ tx_transfer = txf.approve(t['address'], spender_address, value, chain_spec)
+ (tx_hash_hex, tx_signed_raw_hex) = sign_and_register_tx(tx_transfer, chain_str, queue, cache_task='cic_eth.eth.token.otx_cache_approve')
+
+ gas_budget = tx_transfer['gas'] * tx_transfer['gasPrice']
+
+ s = create_check_gas_and_send_task(
+ [tx_signed_raw_hex],
+ chain_str,
+ holder_address,
+ gas_budget,
+ [tx_hash_hex],
+ queue,
+ )
+ s.apply_async()
+ return tx_hash_hex
+
+
+@celery_app.task()
+def resolve_tokens_by_symbol(token_symbols, chain_str):
+ """Returns contract addresses of an array of ERC20 token symbols
+
+ :param token_symbols: Token symbols to resolve
+ :type token_symbols: list of str
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+
+ :return: Respective token contract addresses
+ :rtype: list of str, 0x-hex
+ """
+ tokens = []
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ for token_symbol in token_symbols:
+ token = CICRegistry.get_token(chain_spec, token_symbol)
+ tokens.append({
+ 'address': token.address(),
+ #'converters': [],
+ })
+ return tokens
+
+
+@celery_app.task()
+def otx_cache_transfer(
+ tx_hash_hex,
+ tx_signed_raw_hex,
+ chain_str,
+ ):
+ """Generates and commits transaction cache metadata for an ERC20.transfer or ERC20.transferFrom transaction
+
+ :param tx_hash_hex: Transaction hash
+ :type tx_hash_hex: str, 0x-hex
+ :param tx_signed_raw_hex: Raw signed transaction
+ :type tx_signed_raw_hex: str, 0x-hex
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :returns: Transaction hash and id of cache element in storage backend, respectively
+ :rtype: tuple
+ """
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ tx_signed_raw_bytes = bytes.fromhex(tx_signed_raw_hex[2:])
+ tx = unpack_signed_raw_tx(tx_signed_raw_bytes, chain_spec.chain_id())
+ (txc, cache_id) = cache_transfer_data(tx_hash_hex, tx)
+ return txc
+
+
+@celery_app.task()
+def cache_transfer_data(
+ tx_hash_hex,
+ tx,
+ ):
+ """Helper function for otx_cache_transfer
+
+ :param tx_hash_hex: Transaction hash
+ :type tx_hash_hex: str, 0x-hex
+ :param tx: Signed raw transaction
+ :type tx: str, 0x-hex
+ :returns: Transaction hash and id of cache element in storage backend, respectively
+ :rtype: tuple
+ """
+ tx_data = unpack_transfer(tx['data'])
+ logg.debug('tx data {}'.format(tx_data))
+ logg.debug('tx {}'.format(tx))
+
+ session = SessionBase.create_session()
+ tx_cache = TxCache(
+ tx_hash_hex,
+ tx['from'],
+ tx_data['to'],
+ tx['to'],
+ tx['to'],
+ tx_data['amount'],
+ tx_data['amount'],
+ )
+ session.add(tx_cache)
+ session.commit()
+ cache_id = tx_cache.id
+ session.close()
+ return (tx_hash_hex, cache_id)
+
+
+@celery_app.task()
+def otx_cache_approve(
+ tx_hash_hex,
+ tx_signed_raw_hex,
+ chain_str,
+ ):
+ """Generates and commits transaction cache metadata for an ERC20.approve transaction
+
+ :param tx_hash_hex: Transaction hash
+ :type tx_hash_hex: str, 0x-hex
+ :param tx_signed_raw_hex: Raw signed transaction
+ :type tx_signed_raw_hex: str, 0x-hex
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :returns: Transaction hash and id of cache element in storage backend, respectively
+ :rtype: tuple
+ """
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ tx_signed_raw_bytes = bytes.fromhex(tx_signed_raw_hex[2:])
+ tx = unpack_signed_raw_tx(tx_signed_raw_bytes, chain_spec.chain_id())
+ (txc, cache_id) = cache_approve_data(tx_hash_hex, tx)
+ return txc
+
+
+@celery_app.task()
+def cache_approve_data(
+ tx_hash_hex,
+ tx,
+ ):
+ """Helper function for otx_cache_approve
+
+ :param tx_hash_hex: Transaction hash
+ :type tx_hash_hex: str, 0x-hex
+ :param tx: Signed raw transaction
+ :type tx: str, 0x-hex
+ :returns: Transaction hash and id of cache element in storage backend, respectively
+ :rtype: tuple
+ """
+ tx_data = unpack_approve(tx['data'])
+ logg.debug('tx data {}'.format(tx_data))
+ logg.debug('tx {}'.format(tx))
+
+ session = SessionBase.create_session()
+ tx_cache = TxCache(
+ tx_hash_hex,
+ tx['from'],
+ tx_data['to'],
+ tx['to'],
+ tx['to'],
+ tx_data['amount'],
+ tx_data['amount'],
+ )
+ session.add(tx_cache)
+ session.commit()
+ cache_id = tx_cache.id
+ session.close()
+ return (tx_hash_hex, cache_id)
diff --git a/apps/cic-eth/cic_eth/eth/tx.py b/apps/cic-eth/cic_eth/eth/tx.py
new file mode 100644
index 00000000..c6d72c5b
--- /dev/null
+++ b/apps/cic-eth/cic_eth/eth/tx.py
@@ -0,0 +1,681 @@
+# standard imports
+import logging
+
+# third-party imports
+import celery
+import requests
+import web3
+from cic_registry import zero_address
+from cic_registry.chain import ChainSpec
+
+# local imports
+from .rpc import RpcClient
+from cic_eth.db import Otx, SessionBase
+from cic_eth.db.models.tx import TxCache
+from cic_eth.db.models.lock import Lock
+from cic_eth.db.enum import LockEnum
+from cic_eth.error import PermanentTxError
+from cic_eth.error import TemporaryTxError
+from cic_eth.error import NotLocalTxError
+from cic_eth.queue.tx import create as queue_create
+from cic_eth.queue.tx import get_tx
+from cic_eth.queue.tx import get_nonce_tx
+from cic_eth.error import OutOfGasError
+from cic_eth.error import LockedError
+from cic_eth.eth.util import unpack_signed_raw_tx
+from cic_eth.eth.task import sign_and_register_tx, create_check_gas_and_send_task
+from cic_eth.eth.task import sign_tx
+from cic_eth.eth.nonce import NonceOracle
+from cic_eth.error import AlreadyFillingGasError
+from cic_eth.eth.util import tx_hex_string
+from cic_eth.admin.ctrl import lock_send
+
+celery_app = celery.current_app
+logg = logging.getLogger()
+
+MAX_NONCE_ATTEMPTS = 3
+
+
+# TODO this function is too long
+@celery_app.task(bind=True, throws=(OutOfGasError))
+def check_gas(self, tx_hashes, chain_str, txs=[], address=None, gas_required=None):
+ """Check the gas level of the sender address of a transaction.
+
+ If the account balance is not sufficient for the required gas, gas refill is requested and OutOfGasError raiser.
+
+ If account balance is sufficient, but level of gas before spend is below "safe" threshold, gas refill is requested, and execution continues normally.
+
+ :param tx_hashes: Transaction hashes due to be submitted
+ :type tx_hashes: list of str, 0x-hex
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :param txs: Signed raw transaction data, corresponding to tx_hashes
+ :type txs: list of str, 0x-hex
+ :param address: Sender address
+ :type address: str, 0x-hex
+ :param gas_required: Gas limit * gas price for transaction, (optional, if not set will be retrived from transaction data)
+ :type gas_required: int
+ :return: Signed raw transaction data list
+ :rtype: param txs, unchanged
+ """
+ if len(txs) == 0:
+ for i in range(len(tx_hashes)):
+ o = get_tx(tx_hashes[i])
+ txs.append(o['signed_tx'])
+ logg.debug('ooooo {}'.format(o))
+ if address == None:
+ address = o['address']
+
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+
+ queue = self.request.delivery_info['routing_key']
+
+ #c = RpcClient(chain_spec, holder_address=address)
+ c = RpcClient(chain_spec)
+
+ # TODO: it should not be necessary to pass address explicitly, if not passed should be derived from the tx
+ balance = c.w3.eth.getBalance(address)
+ logg.debug('check gas txs {}'.format(tx_hashes))
+ logg.debug('address {} has gas {} needs {}'.format(address, balance, gas_required))
+
+ if gas_required > balance:
+ s_refill_gas = celery.signature(
+ 'cic_eth.eth.tx.refill_gas',
+ [
+ address,
+ chain_str,
+ ],
+ queue=queue,
+ )
+ s_refill_gas.apply_async()
+ wait_tasks = []
+ for tx_hash in tx_hashes:
+ s = celery.signature(
+ 'cic_eth.queue.tx.set_waitforgas',
+ [
+ tx_hash,
+ ],
+ queue=queue,
+ )
+ wait_tasks.append(s)
+ celery.group(wait_tasks)()
+ raise OutOfGasError('need to fill gas, required {}, had {}'.format(gas_required, balance))
+
+ safe_gas = c.safe_threshold_amount()
+ if balance < safe_gas:
+ s_refill_gas = celery.signature(
+ 'cic_eth.eth.tx.refill_gas',
+ [
+ address,
+ chain_str,
+ ],
+ queue=queue,
+ )
+ s_refill_gas.apply_async()
+ logg.debug('requested refill from {} to {}'.format(c.gas_provider(), address))
+ ready_tasks = []
+ for tx_hash in tx_hashes:
+ s = celery.signature(
+ 'cic_eth.queue.tx.set_ready',
+ [
+ tx_hash,
+ ],
+ queue=queue,
+ )
+ ready_tasks.append(s)
+ logg.debug('tasks {}'.format(ready_tasks))
+ celery.group(ready_tasks)()
+
+ return txs
+
+
+# TODO: chain chainable transactions that use hashes as inputs may be chained to this function to output signed txs instead.
+@celery_app.task(bind=True)
+def hashes_to_txs(self, tx_hashes):
+ """Return a list of raw signed transactions from the local transaction queue corresponding to a list of transaction hashes.
+
+ :param tx_hashes: Transaction hashes
+ :type tx_hashes: list of str, 0x-hex
+ :raises ValueError: Empty input list
+ :returns: Signed raw transactions
+ :rtype: list of str, 0x-hex
+ """
+ #logg = celery_app.log.get_default_logger()
+ if len(tx_hashes) == 0:
+ raise ValueError('no transaction to send')
+
+ queue = self.request.delivery_info['routing_key']
+
+ #otxs = ','.format("'{}'".format(tx_hash) for tx_hash in tx_hashes)
+
+ session = SessionBase.create_session()
+ q = session.query(Otx.signed_tx)
+ q = q.filter(Otx.tx_hash.in_(tx_hashes))
+ tx_tuples = q.all()
+ session.close()
+
+ def __head(x):
+ return x[0]
+
+ txs = []
+ for f in map(__head, tx_tuples):
+ txs.append(f)
+
+ return txs
+
+
+# TODO: Move this and send to subfolder submodule
+class ParityNodeHandler:
+ def __init__(self, chain_spec, queue):
+ self.chain_spec = chain_spec
+ self.chain_str = str(chain_spec)
+ self.queue = queue
+
+ def handle(self, exception, tx_hash_hex, tx_hex):
+ meth = self.handle_default
+ if isinstance(exception, (ValueError)):
+# s_debug = celery.signature(
+# 'cic_eth.admin.debug.out_tmp',
+# [tx_hash_hex, '{}: {}'.format(tx_hash_hex, exception)],
+# queue=queue,
+# )
+# s_debug.apply_async()
+ earg = exception.args[0]
+ if earg['code'] == -32010:
+ logg.debug('skipping lock for code {}'.format(earg['code']))
+ meth = self.handle_invalid_parameters
+ elif earg['code'] == -32602:
+ meth = self.handle_invalid_encoding
+ else:
+ meth = self.handle_invalid
+ elif isinstance(exception, (requests.exceptions.ConnectionError)):
+ meth = self.handle_connection
+ (t, e_fn, message) = meth(tx_hash_hex, tx_hex)
+ return (t, e_fn, '{} {}'.format(message, exception))
+
+
+ def handle_connection(self, tx_hash_hex, tx_hex):
+ s_set_sent = celery.signature(
+ 'cic_eth.queue.tx.set_sent_status',
+ [
+ tx_hash_hex,
+ True,
+ ],
+ queue=self.queue,
+ )
+ t = s_set_sent.apply_async()
+ return (t, TemporaryTxError, 'Sendfail {}'.format(tx_hex_string(tx_hex, self.chain_spec.chain_id())))
+
+
+ def handle_invalid_encoding(self, tx_hash_hex, tx_hex):
+ tx_bytes = bytes.fromhex(tx_hex[2:])
+ tx = unpack_signed_raw_tx(tx_bytes, self.chain_spec.chain_id())
+ s_lock = celery.signature(
+ 'cic_eth.admin.ctrl.lock_send',
+ [
+ tx_hash_hex,
+ self.chain_str,
+ tx['from'],
+ tx_hash_hex,
+ ],
+ queue=self.queue,
+ )
+ s_set_reject = celery.signature(
+ 'cic_eth.queue.tx.set_rejected',
+ [],
+ queue=self.queue,
+ )
+ nonce_txs = get_nonce_tx(tx['nonce'], tx['from'], self.chain_spec.chain_id())
+ attempts = len(nonce_txs)
+ if attempts < MAX_NONCE_ATTEMPTS:
+ logg.debug('nonce {} address {} retries {} < {}'.format(tx['nonce'], tx['from'], attempts, MAX_NONCE_ATTEMPTS))
+ s_resend = celery.signature(
+ 'cic_eth.eth.tx.resend_with_higher_gas',
+ [
+ self.chain_str,
+ None,
+ 1.01,
+ ],
+ queue=self.queue,
+ )
+ s_unlock = celery.signature(
+ 'cic_eth.admin.ctrl.unlock_send',
+ [
+ self.chain_str,
+ tx['from'],
+ ],
+ queue=self.queue,
+ )
+ s_resend.link(s_unlock)
+ s_set_reject.link(s_resend)
+
+ s_lock.link(s_set_reject)
+ t = s_lock.apply_async()
+ return (t, PermanentTxError, 'Reject invalid encoding {}'.format(tx_hex_string(tx_hex, self.chain_spec.chain_id())))
+
+
+ def handle_invalid_parameters(self, tx_hash_hex, tx_hex):
+ s_sync = celery.signature(
+ 'cic_eth.eth.tx.sync_tx',
+ [
+ tx_hash_hex,
+ self.chain_str,
+ ],
+ queue=self.queue,
+ )
+ t = s_sync.apply_async()
+ return (t, PermanentTxError, 'Reject invalid parameters {}'.format(tx_hex_string(tx_hex, self.chain_spec.chain_id())))
+
+
+ def handle_invalid(self, tx_hash_hex, tx_hex):
+ tx_bytes = bytes.fromhex(tx_hex[2:])
+ tx = unpack_signed_raw_tx(tx_bytes, self.chain_spec.chain_id())
+ s_lock = celery.signature(
+ 'cic_eth.admin.ctrl.lock_send',
+ [
+ tx_hash_hex,
+ self.chain_str,
+ tx['from'],
+ tx_hash_hex,
+ ],
+ queue=self.queue,
+ )
+ s_set_reject = celery.signature(
+ 'cic_eth.queue.tx.set_rejected',
+ [],
+ queue=self.queue,
+ )
+ s_lock.link(s_set_reject)
+ t = s_lock.apply_async()
+ return (t, PermanentTxError, 'Reject invalid {}'.format(tx_hex_string(tx_hex, self.chain_spec.chain_id())))
+
+
+ def handle_default(self, tx_hash_hex, tx_hex):
+ tx_bytes = bytes.fromhex(tx_hex[2:])
+ tx = unpack_signed_raw_tx(tx_bytes, self.chain_spec.chain_id())
+ s_lock = celery.signature(
+ 'cic_eth.admin.ctrl.lock_send',
+ [
+ tx_hash_hex,
+ self.chain_str,
+ tx['from'],
+ tx_hash_hex,
+ ],
+ queue=self.queue,
+ )
+ s_set_fubar = celery.signature(
+ 'cic_eth.queue.tx.set_fubar',
+ [],
+ queue=self.queue,
+ )
+ s_lock.link(s_set_fubar)
+ t = s_lock.apply_async()
+ return (t, PermanentTxError, 'Fubar {}'.format(tx_hex_string(tx_hex, self.chain_spec.chain_id())))
+
+
+@celery_app.task(bind=True)
+def send(self, txs, chain_str):
+ """Send transactions to the network.
+
+ If more than one transaction is passed to the task, it will spawn a new send task with the remaining transaction(s) after the first in the list has been processed.
+
+ Updates the outgoing transaction queue entry to SENT on successful send.
+
+ If a temporary error occurs, the queue entry is set to SENDFAIL.
+
+ If a permanent error occurs due to invalid transaction data, queue entry value is set to REJECTED.
+
+ Any other permanent error that isn't explicitly handled will get value FUBAR.
+
+ :param txs: Signed raw transaction data
+ :type txs: list of str, 0x-hex
+ :param chain_str: Chain spec, string representation
+ :type chain_str: str
+ :raises TemporaryTxError: If unable to connect to node
+ :raises PermanentTxError: If EVM execution fails immediately due to tx input, or if tx contents are invalid.
+ :return: transaction hash of sent transaction
+ :rtype: str, 0x-hex
+ """
+ if len(txs) == 0:
+ raise ValueError('no transaction to send')
+
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+
+
+ tx_hex = txs[0]
+ logg.debug('send transaction {}'.format(tx_hex))
+
+ tx_hash = web3.Web3.keccak(hexstr=tx_hex)
+ tx_hash_hex = tx_hash.hex()
+
+ queue = self.request.delivery_info.get('routing_key', None)
+ if queue == None:
+ logg.debug('send tx {} has no queue', tx_hash)
+
+ c = RpcClient(chain_spec)
+ r = None
+ try:
+ r = c.w3.eth.send_raw_transaction(tx_hex)
+ except Exception as e:
+ logg.debug('e {}'.format(e))
+ raiser = ParityNodeHandler(chain_spec, queue)
+ (t, e, m) = raiser.handle(e, tx_hash_hex, tx_hex)
+ raise e(m)
+
+ s_set_sent = celery.signature(
+ 'cic_eth.queue.tx.set_sent_status',
+ [
+ tx_hash_hex,
+ False
+ ],
+ queue=queue,
+ )
+ s_set_sent.apply_async()
+
+ tx_tail = txs[1:]
+ if len(tx_tail) > 0:
+ s = celery.signature(
+ 'cic_eth.eth.tx.send',
+ [tx_tail],
+ queue=queue,
+ )
+ s.apply_async()
+
+ return r.hex()
+
+
+@celery_app.task(bind=True, throws=(AlreadyFillingGasError))
+def refill_gas(self, recipient_address, chain_str):
+ """Executes a native token transaction to fund the recipient's gas expenditures.
+
+ :param recipient_address: Recipient in need of gas
+ :type recipient_address: str, 0x-hex
+ :param chain_str: Chain spec, string representation
+ :type chain_str: str
+ :raises AlreadyFillingGasError: A gas refill transaction for this address is already executing
+ :returns: Transaction hash.
+ :rtype: str, 0x-hex
+ """
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+
+ session = SessionBase.create_session()
+ q = session.query(Otx.tx_hash)
+ q = q.join(TxCache)
+ q = q.filter(Otx.status<=0)
+ q = q.filter(TxCache.from_value!='0x00')
+ q = q.filter(TxCache.recipient==recipient_address)
+ c = q.count()
+ session.close()
+ if c > 0:
+ raise AlreadyFillingGasError(recipient_address)
+
+ queue = self.request.delivery_info['routing_key']
+
+ c = RpcClient(chain_spec)
+ clogg = celery_app.log.get_default_logger()
+ logg.debug('refill gas from provider address {}'.format(c.gas_provider()))
+ default_nonce = c.w3.eth.getTransactionCount(c.gas_provider(), 'pending')
+ nonce_generator = NonceOracle(c.gas_provider(), default_nonce)
+ nonce = nonce_generator.next()
+ gas_price = c.gas_price()
+ gas_limit = c.default_gas_limit
+ refill_amount = c.refill_amount()
+ logg.debug('gas price {} nonce {}'.format(gas_price, nonce))
+
+ # create and sign transaction
+ tx_send_gas = {
+ 'from': c.gas_provider(),
+ 'to': recipient_address,
+ 'gas': gas_limit,
+ 'gasPrice': gas_price,
+ 'chainId': chain_spec.chain_id(),
+ 'nonce': nonce,
+ 'value': refill_amount,
+ 'data': '',
+ }
+ logg.debug('txsend_gas {}'.format(tx_send_gas))
+ tx_send_gas_signed = c.w3.eth.sign_transaction(tx_send_gas)
+ tx_hash = web3.Web3.keccak(hexstr=tx_send_gas_signed['raw'])
+ tx_hash_hex = tx_hash.hex()
+
+ # TODO: route this through sign_and_register_tx instead
+ logg.debug('adding queue refill gas tx {}'.format(tx_hash_hex))
+ queue_create(
+ nonce,
+ c.gas_provider(),
+ tx_hash_hex,
+ tx_send_gas_signed['raw'],
+ chain_str,
+ )
+
+ s_tx_cache = celery.signature(
+ 'cic_eth.eth.tx.cache_gas_refill_data',
+ [
+ tx_hash_hex,
+ tx_send_gas,
+ ],
+ queue=queue,
+ )
+ s_status = celery.signature(
+ 'cic_eth.queue.tx.set_ready',
+ [
+ tx_hash_hex,
+ ],
+ queue=queue,
+ )
+ celery.group(s_tx_cache, s_status)()
+ return tx_send_gas_signed['raw']
+
+
+@celery_app.task(bind=True)
+def resend_with_higher_gas(self, txold_hash_hex, chain_str, gas=None, default_factor=1.1):
+ """Create a new transaction from an existing one with same nonce and higher gas price.
+
+ :param txold_hash_hex: Transaction to re-create
+ :type txold_hash_hex: str, 0x-hex
+ :param chain_str: Chain spec, string representation
+ :type chain_str: str
+ :param gas: Explicitly use the specified gas amount
+ :type gas: number
+ :param default_factor: Default factor by which to increment the gas price by
+ :type default_factor: float
+ :raises NotLocalTxError: Transaction does not exist in the local queue
+ :returns: Transaction hash
+ :rtype: str, 0x-hex
+ """
+ session = SessionBase.create_session()
+ otx = session.query(Otx).filter(Otx.tx_hash==txold_hash_hex).first()
+ if otx == None:
+ session.close()
+ raise NotLocalTxError(txold_hash_hex)
+ session.close()
+
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ c = RpcClient(chain_spec)
+
+ tx_signed_raw_bytes = bytes.fromhex(otx.signed_tx[2:])
+ tx = unpack_signed_raw_tx(tx_signed_raw_bytes, chain_spec.chain_id())
+ logg.debug('otx {} {}'.format(tx, otx.signed_tx))
+
+ queue = self.request.delivery_info['routing_key']
+
+ logg.debug('before {}'.format(tx))
+ if gas != None:
+ tx['gasPrice'] = gas
+ else:
+ gas_price = c.gas_price()
+ if tx['gasPrice'] > gas_price:
+ logg.warning('Network gas price {} is lower than overdue tx gas price {}'.format(gas_price, tx['gasPrice']))
+ #tx['gasPrice'] = int(tx['gasPrice'] * default_factor)
+ tx['gasPrice'] += 1
+ else:
+ new_gas_price = int(tx['gasPrice'] * default_factor)
+ if gas_price > new_gas_price:
+ tx['gasPrice'] = gas_price
+ else:
+ tx['gasPrice'] = new_gas_price
+
+ logg.debug('after {}'.format(tx))
+
+ #(tx_hash_hex, tx_signed_raw_hex) = sign_and_register_tx(tx, chain_str, queue)
+ (tx_hash_hex, tx_signed_raw_hex) = sign_tx(tx, chain_str)
+ queue_create(
+ tx['nonce'],
+ tx['from'],
+ tx_hash_hex,
+ tx_signed_raw_hex,
+ chain_str,
+ )
+ TxCache.clone(txold_hash_hex, tx_hash_hex)
+
+ s = create_check_gas_and_send_task(
+ [tx_signed_raw_hex],
+ chain_str,
+ tx['from'],
+ tx['gasPrice'] * tx['gas'],
+ [tx_hash_hex],
+ queue=queue,
+ )
+ s.apply_async()
+ return tx_hash_hex
+
+
+@celery_app.task(bind=True, throws=(web3.exceptions.TransactionNotFound,))
+def sync_tx(self, tx_hash_hex, chain_str):
+
+ queue = self.request.delivery_info['routing_key']
+
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ c = RpcClient(chain_spec)
+
+ tx = c.w3.eth.getTransaction(tx_hash_hex)
+ rcpt = None
+ try:
+ rcpt = c.w3.eth.getTransactionReceipt(tx_hash_hex)
+ except web3.exceptions.TransactionNotFound as e:
+ pass
+
+ if rcpt != None:
+ success = rcpt['status'] == 1
+ logg.debug('sync tx {} mined block {} success {}'.format(tx_hash_hex, rcpt['blockNumber'], success))
+
+ s = celery.signature(
+ 'cic_eth.queue.tx.set_final_status',
+ [
+ tx_hash_hex,
+ rcpt['blockNumber'],
+ not success,
+ ],
+ queue=queue,
+ )
+ else:
+ logg.debug('sync tx {} mempool'.format(tx_hash_hex))
+
+ s = celery.signature(
+ 'cic_eth.queue.tx.set_sent_status',
+ [
+ tx_hash_hex,
+ ],
+ queue=queue,
+ )
+
+ s.apply_async()
+
+
+
+@celery_app.task(bind=True)
+def resume_tx(self, txpending_hash_hex, chain_str):
+ """Queue a suspended tranaction for (re)sending
+
+ :param txpending_hash_hex: Transaction hash
+ :type txpending_hash_hex: str, 0x-hex
+ :param chain_str: Chain spec, string representation
+ :type chain_str: str
+ :raises NotLocalTxError: Transaction does not exist in the local queue
+ :returns: Transaction hash
+ :rtype: str, 0x-hex
+ """
+
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+
+ session = SessionBase.create_session()
+ r = session.query(Otx.signed_tx).filter(Otx.tx_hash==txpending_hash_hex).first()
+ session.close()
+ if r == None:
+ raise NotLocalTxError(txpending_hash_hex)
+
+ tx_signed_raw_hex = r[0]
+ tx_signed_bytes = bytes.fromhex(tx_signed_raw_hex[2:])
+ tx = unpack_signed_raw_tx(tx_signed_bytes, chain_spec.chain_id())
+
+ queue = self.request.delivery_info['routing_key']
+
+ s = create_check_gas_and_send_task(
+ [tx_signed_raw_hex],
+ chain_str,
+ tx['from'],
+ tx['gasPrice'] * tx['gas'],
+ [txpending_hash_hex],
+ queue=queue,
+ )
+ s.apply_async()
+ return txpending_hash_hex
+
+
+@celery_app.task()
+def otx_cache_parse_tx(
+ tx_hash_hex,
+ tx_signed_raw_hex,
+ chain_str,
+ ):
+ """Generates and commits transaction cache metadata for a gas refill transaction
+
+ :param tx_hash_hex: Transaction hash
+ :type tx_hash_hex: str, 0x-hex
+ :param tx_signed_raw_hex: Raw signed transaction
+ :type tx_signed_raw_hex: str, 0x-hex
+ :param chain_str: Chain spec string representation
+ :type chain_str: str
+ :returns: Transaction hash and id of cache element in storage backend, respectively
+ :rtype: tuple
+ """
+
+
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ c = RpcClient(chain_spec)
+ tx_signed_raw_bytes = bytes.fromhex(tx_signed_raw_hex[2:])
+ tx = unpack_signed_raw_tx(tx_signed_raw_bytes, chain_spec.chain_id())
+ (txc, cache_id) = cache_gas_refill_data(tx_hash_hex, tx)
+ return txc
+
+
+@celery_app.task()
+def cache_gas_refill_data(
+ tx_hash_hex,
+ tx,
+ ):
+ """Helper function for otx_cache_parse_tx
+
+ :param tx_hash_hex: Transaction hash
+ :type tx_hash_hex: str, 0x-hex
+ :param tx: Signed raw transaction
+ :type tx: str, 0x-hex
+ :returns: Transaction hash and id of cache element in storage backend, respectively
+ :rtype: tuple
+ """
+ tx_cache = TxCache(
+ tx_hash_hex,
+ tx['from'],
+ tx['to'],
+ zero_address,
+ zero_address,
+ tx['value'],
+ tx['value'],
+ )
+
+ session = SessionBase.create_session()
+ session.add(tx_cache)
+ session.commit()
+ cache_id = tx_cache.id
+ session.close()
+ return (tx_hash_hex, cache_id)
diff --git a/apps/cic-eth/cic_eth/eth/util.py b/apps/cic-eth/cic_eth/eth/util.py
new file mode 100644
index 00000000..4bd2dea6
--- /dev/null
+++ b/apps/cic-eth/cic_eth/eth/util.py
@@ -0,0 +1,102 @@
+# standard imports
+import logging
+import sha3
+import web3
+
+# third-party imports
+from rlp import decode as rlp_decode
+from rlp import encode as rlp_encode
+from eth_keys import KeyAPI
+
+logg = logging.getLogger()
+
+field_debugs = [
+ 'nonce',
+ 'gasPrice',
+ 'gas',
+ 'to',
+ 'value',
+ 'data',
+ 'v',
+ 'r',
+ 's',
+ ]
+
+
+def unpack_signed_raw_tx(tx_raw_bytes, chain_id):
+ d = rlp_decode(tx_raw_bytes)
+
+ logg.debug('decoding using chain id {}'.format(chain_id))
+ j = 0
+ for i in d:
+ logg.debug('decoded {}: {}'.format(field_debugs[j], i.hex()))
+ j += 1
+ vb = chain_id
+ if chain_id != 0:
+ v = int.from_bytes(d[6], 'big')
+ vb = v - (chain_id * 2) - 35
+ s = b''.join([d[7], d[8], bytes([vb])])
+ so = KeyAPI.Signature(signature_bytes=s)
+
+ h = sha3.keccak_256()
+ h.update(rlp_encode(d))
+ signed_hash = h.digest()
+
+ d[6] = chain_id
+ d[7] = b''
+ d[8] = b''
+
+ h = sha3.keccak_256()
+ h.update(rlp_encode(d))
+ unsigned_hash = h.digest()
+
+ p = so.recover_public_key_from_msg_hash(unsigned_hash)
+ a = p.to_checksum_address()
+ logg.debug('decoded recovery byte {}'.format(vb))
+ logg.debug('decoded address {}'.format(a))
+ logg.debug('decoded signed hash {}'.format(signed_hash.hex()))
+ logg.debug('decoded unsigned hash {}'.format(unsigned_hash.hex()))
+
+ to = d[3].hex() or None
+ if to != None:
+ to = web3.Web3.toChecksumAddress('0x' + to)
+
+ return {
+ 'from': a,
+ 'nonce': int.from_bytes(d[0], 'big'),
+ 'gasPrice': int.from_bytes(d[1], 'big'),
+ 'gas': int.from_bytes(d[2], 'big'),
+ 'to': to,
+ 'value': int.from_bytes(d[4], 'big'),
+ 'data': '0x' + d[5].hex(),
+ 'v': chain_id,
+ 'r': '0x' + s[:32].hex(),
+ 's': '0x' + s[32:64].hex(),
+ 'chainId': chain_id,
+ 'hash': '0x' + signed_hash.hex(),
+ 'hash_unsigned': '0x' + unsigned_hash.hex(),
+ }
+
+
+def unpack_signed_raw_tx_hex(tx_raw_hex, chain_id):
+ return unpack_signed_raw_tx(bytes.fromhex(tx_raw_hex[2:]), chain_id)
+
+
+# TODO: consider moving tx string representation generation from api_admin to here
+def tx_string(tx_raw_bytes, chain_id):
+ tx_unpacked = unpack_signed_raw_tx(tx_raw_bytes, chain_id)
+ return 'tx nonce {} from {} to {} hash {}'.format(
+ tx_unpacked['nonce'],
+ tx_unpacked['from'],
+ tx_unpacked['to'],
+ tx_unpacked['hash'],
+ )
+
+def tx_hex_string(tx_hex, chain_id):
+ if len(tx_hex) < 2:
+ raise ValueError('invalid data length')
+ elif tx_hex[:2] == '0x':
+ tx_hex = tx_hex[2:]
+
+ tx_raw_bytes = bytes.fromhex(tx_hex)
+ return tx_string(tx_raw_bytes, chain_id)
diff --git a/apps/cic-eth/cic_eth/queue/__init__.py b/apps/cic-eth/cic_eth/queue/__init__.py
new file mode 100644
index 00000000..8acee1b9
--- /dev/null
+++ b/apps/cic-eth/cic_eth/queue/__init__.py
@@ -0,0 +1,4 @@
+# third-party imports
+import celery
+
+from .tx import get_tx
diff --git a/apps/cic-eth/cic_eth/queue/tx.py b/apps/cic-eth/cic_eth/queue/tx.py
new file mode 100644
index 00000000..bcc2bed3
--- /dev/null
+++ b/apps/cic-eth/cic_eth/queue/tx.py
@@ -0,0 +1,654 @@
+# standard imports
+import logging
+import time
+import datetime
+
+# third-party imports
+import celery
+from sqlalchemy import or_
+from sqlalchemy import tuple_
+from sqlalchemy import func
+
+# local imports
+from cic_registry import CICRegistry
+from cic_eth.db.models.otx import Otx
+from cic_eth.db.models.otx import OtxStateLog
+from cic_eth.db.models.tx import TxCache
+from cic_eth.db.models.lock import Lock
+from cic_eth.db import SessionBase
+from cic_eth.db.enum import StatusEnum
+from cic_eth.db.enum import LockEnum
+from cic_eth.eth.util import unpack_signed_raw_tx # TODO: should not be in same sub-path as package that imports queue.tx
+from cic_eth.error import NotLocalTxError
+from cic_eth.error import LockedError
+
+celery_app = celery.current_app
+#logg = celery_app.log.get_default_logger()
+logg = logging.getLogger()
+
+
+@celery_app.task()
+def create(nonce, holder_address, tx_hash, signed_tx, chain_str, obsolete_predecessors=True):
+ """Create a new transaction queue record.
+
+ :param nonce: Transaction nonce
+ :type nonce: int
+ :param holder_address: Sender address
+ :type holder_address: str, 0x-hex
+ :param tx_hash: Transaction hash
+ :type tx_hash: str, 0x-hex
+ :param signed_tx: Signed raw transaction
+ :type signed_tx: str, 0x-hex
+ :param chain_str: Chain spec string representation to create transaction for
+ :type chain_str: str
+ :returns: transaction hash
+ :rtype: str, 0x-hash
+ """
+ session = SessionBase.create_session()
+ lock = Lock.check_aggregate(chain_str, LockEnum.QUEUE, holder_address, session=session)
+ if lock > 0:
+ session.close()
+ raise LockedError(lock)
+
+ o = Otx.add(
+ nonce=nonce,
+ address=holder_address,
+ tx_hash=tx_hash,
+ signed_tx=signed_tx,
+ session=session,
+ )
+ session.flush()
+
+ if obsolete_predecessors:
+ # TODO: obsolete previous txs from same holder with same nonce
+ q = session.query(Otx)
+ q = q.join(TxCache)
+ q = q.filter(Otx.nonce==nonce)
+ q = q.filter(TxCache.sender==holder_address)
+ q = q.filter(Otx.tx_hash!=tx_hash)
+ q = q.filter(Otx.status<=StatusEnum.SENT)
+
+ for otx in q.all():
+ logg.info('otx {} obsoleted by {}'.format(otx.tx_hash, tx_hash))
+ if otx.status == StatusEnum.SENT:
+ otx.cancel(False, session=session)
+ elif otx.status != StatusEnum.OBSOLETED:
+ otx.override(session=session)
+
+ session.commit()
+ session.close()
+ logg.debug('queue created nonce {} from {} hash {}'.format(nonce, holder_address, tx_hash))
+ return tx_hash
+
+
+# TODO: Replace set_* with single task for set status
+@celery_app.task()
+def set_sent_status(tx_hash, fail=False):
+ """Used to set the status after a send attempt
+
+ :param tx_hash: Transaction hash of record to modify
+ :type tx_hash: str, 0x-hex
+ :param fail: if True, will set a SENDFAIL status, otherwise a SENT status. (Default: False)
+ :type fail: boolean
+ :raises NotLocalTxError: If transaction not found in queue.
+ :returns: True if tx is known, False otherwise
+ :rtype: boolean
+ """
+ session = SessionBase.create_session()
+ o = session.query(Otx).filter(Otx.tx_hash==tx_hash).first()
+ if o == None:
+ logg.warning('not local tx, skipping {}'.format(tx_hash))
+ session.close()
+ return False
+
+ if fail:
+ o.sendfail(session=session)
+ else:
+ o.sent(session=session)
+
+ session.commit()
+ session.close()
+
+ return tx_hash
+
+
+@celery_app.task()
+def set_final_status(tx_hash, block=None, fail=False):
+ """Used to set the status of an incoming transaction result.
+
+ :param tx_hash: Transaction hash of record to modify
+ :type tx_hash: str, 0x-hex
+ :param block: Block number if final status represents a confirmation on the network
+ :type block: number
+ :param fail: if True, will set a SUCCESS status, otherwise a REVERTED status. (Default: False)
+ :type fail: boolean
+ :raises NotLocalTxError: If transaction not found in queue.
+ """
+ session = SessionBase.create_session()
+ q = session.query(
+ Otx.nonce.label('nonce'),
+ TxCache.sender.label('sender'),
+ Otx.id.label('otxid'),
+ )
+ q = q.join(TxCache)
+ q = q.filter(Otx.tx_hash==tx_hash)
+ o = q.first()
+
+ if o == None:
+ session.close()
+ raise NotLocalTxError('queue does not contain tx hash {}'.format(tx_hash))
+
+ session.flush()
+
+ nonce = o.nonce
+ sender = o.sender
+ otxid = o.otxid
+
+ q = session.query(Otx)
+ q = q.filter(Otx.tx_hash==tx_hash)
+ o = q.first()
+
+ if fail:
+ o.minefail(block, session=session)
+ else:
+ o.success(block, session=session)
+
+ q = session.query(Otx)
+ q = q.join(TxCache)
+ q = q.filter(Otx.nonce==nonce)
+ q = q.filter(TxCache.sender==sender)
+ q = q.filter(Otx.tx_hash!=tx_hash)
+
+ for otwo in q.all():
+ otwo.cancel(True, session=session)
+
+ session.commit()
+ session.close()
+
+ return tx_hash
+
+@celery_app.task()
+def set_cancel(tx_hash, manual=False):
+ """Used to set the status when a transaction is cancelled.
+
+ Will set the state to CANCELLED or OVERRIDDEN
+
+ :param tx_hash: Transaction hash of record to modify
+ :type tx_hash: str, 0x-hex
+ :param manual: If set, status will be OVERRIDDEN. Otherwise CANCELLED.
+ :type manual: boolean
+ :raises NotLocalTxError: If transaction not found in queue.
+ """
+
+ session = SessionBase.create_session()
+ o = session.query(Otx).filter(Otx.tx_hash==tx_hash).first()
+ if o == None:
+ session.close()
+ raise NotLocalTxError('queue does not contain tx hash {}'.format(tx_hash))
+
+ session.flush()
+
+ if manual:
+ o.override(session=session)
+ else:
+ o.cancel(session=session)
+
+ session.commit()
+ session.close()
+
+ return tx_hash
+
+
+@celery_app.task()
+def set_rejected(tx_hash):
+ """Used to set the status when the node rejects sending a transaction to network
+
+ Will set the state to REJECTED
+
+ :param tx_hash: Transaction hash of record to modify
+ :type tx_hash: str, 0x-hex
+ :raises NotLocalTxError: If transaction not found in queue.
+ """
+
+ session = SessionBase.create_session()
+ o = session.query(Otx).filter(Otx.tx_hash==tx_hash).first()
+ if o == None:
+ session.close()
+ raise NotLocalTxError('queue does not contain tx hash {}'.format(tx_hash))
+
+ session.flush()
+
+ o.reject(session=session)
+ session.commit()
+ session.close()
+
+ return tx_hash
+
+
+@celery_app.task()
+def set_fubar(tx_hash):
+ """Used to set the status when an unexpected error occurs.
+
+ Will set the state to FUBAR
+
+ :param tx_hash: Transaction hash of record to modify
+ :type tx_hash: str, 0x-hex
+ :raises NotLocalTxError: If transaction not found in queue.
+ """
+
+ session = SessionBase.create_session()
+ o = session.query(Otx).filter(Otx.tx_hash==tx_hash).first()
+ if o == None:
+ session.close()
+ raise NotLocalTxError('queue does not contain tx hash {}'.format(tx_hash))
+
+ session.flush()
+
+ o.fubar(session=session)
+ session.commit()
+ session.close()
+
+ return tx_hash
+
+@celery_app.task()
+def set_ready(tx_hash):
+ """Used to mark a transaction as ready to be sent to network
+
+ :param tx_hash: Transaction hash of record to modify
+ :type tx_hash: str, 0x-hex
+ :raises NotLocalTxError: If transaction not found in queue.
+ """
+ session = SessionBase.create_session()
+ o = session.query(Otx).filter(Otx.tx_hash==tx_hash).first()
+ if o == None:
+ session.close()
+ raise NotLocalTxError('queue does not contain tx hash {}'.format(tx_hash))
+ session.flush()
+
+ if o.status == StatusEnum.WAITFORGAS or o.status == StatusEnum.PENDING:
+ o.readysend(session=session)
+ else:
+ o.retry(session=session)
+
+ logg.debug('ot otx otx {} {}'.format(tx_hash, o))
+
+ session.add(o)
+ session.commit()
+ session.close()
+
+ return tx_hash
+
+
+@celery_app.task()
+def set_waitforgas(tx_hash):
+ """Used to set the status when a transaction must be deferred due to gas refill
+
+ Will set the state to WAITFORGAS
+
+ :param tx_hash: Transaction hash of record to modify
+ :type tx_hash: str, 0x-hex
+ :raises NotLocalTxError: If transaction not found in queue.
+ """
+
+ session = SessionBase.create_session()
+ o = session.query(Otx).filter(Otx.tx_hash==tx_hash).first()
+ if o == None:
+ session.close()
+ raise NotLocalTxError('queue does not contain tx hash {}'.format(tx_hash))
+
+ session.flush()
+
+ o.waitforgas(session=session)
+ session.commit()
+ session.close()
+
+ return tx_hash
+
+@celery_app.task()
+def get_state_log(tx_hash):
+
+ logs = []
+
+ session = SessionBase.create_session()
+
+ q = session.query(OtxStateLog)
+ q = q.join(Otx)
+ q = q.filter(Otx.tx_hash==tx_hash)
+ q = q.order_by(OtxStateLog.date.asc())
+ for l in q.all():
+ logs.append((l.date, l.status,))
+
+ session.close()
+
+ return logs
+
+
+@celery_app.task()
+def get_tx_cache(tx_hash):
+ """Returns an aggregate dictionary of outgoing transaction data and metadata
+
+ :param tx_hash: Transaction hash of record to modify
+ :type tx_hash: str, 0x-hex
+ :raises NotLocalTxError: If transaction not found in queue.
+ :returns: Transaction data
+ :rtype: dict
+ """
+ session = SessionBase.create_session()
+ q = session.query(Otx)
+ q = q.filter(Otx.tx_hash==tx_hash)
+ otx = q.first()
+
+ if otx == None:
+ session.close()
+ raise NotLocalTxError(tx_hash)
+
+ session.flush()
+
+ q = session.query(TxCache)
+ q = q.filter(TxCache.otx_id==otx.id)
+ txc = q.first()
+
+ session.close()
+
+ values = txc.values()
+ tx = {
+ 'tx_hash': otx.tx_hash,
+ 'signed_tx': otx.signed_tx,
+ 'nonce': otx.nonce,
+ 'status': StatusEnum(otx.status).name,
+ 'status_code': otx.status,
+ 'source_token': txc.source_token_address,
+ 'destination_token': txc.destination_token_address,
+ 'sender': txc.sender,
+ 'recipient': txc.recipient,
+ 'from_value': values[0],
+ 'to_value': values[1],
+ 'date_created': txc.date_created,
+ 'date_updated': txc.date_updated,
+ 'date_checked': txc.date_checked,
+ }
+
+ return tx
+
+
+@celery_app.task()
+def get_lock(address=None):
+ """Retrieve all active locks
+
+ If address is set, the query will look up the lock for the specified address only. A list of zero or one elements is returned, depending on whether a lock is set or not.
+
+ :param address: Get lock for only the specified address
+ :type address: str, 0x-hex
+ :returns: List of locks
+ :rtype: list of dicts
+ """
+ session = SessionBase.create_session()
+ q = session.query(
+ Lock.date_created,
+ Lock.address,
+ Lock.flags,
+ Otx.tx_hash,
+ )
+ q = q.join(Otx, isouter=True)
+ if address != None:
+ q = q.filter(Lock.address==address)
+ else:
+ q = q.order_by(Lock.date_created.asc())
+
+ locks = []
+ for lock in q.all():
+ o = {
+ 'date': lock[0],
+ 'address': lock[1],
+ 'tx_hash': lock[3],
+ 'flags': lock[2],
+ }
+ locks.append(o)
+ session.close()
+
+ return locks
+
+
+@celery_app.task()
+def get_tx(tx_hash):
+ """Retrieve a transaction queue record by transaction hash
+
+ :param tx_hash: Transaction hash of record to modify
+ :type tx_hash: str, 0x-hex
+ :raises NotLocalTxError: If transaction not found in queue.
+ :returns: nonce, address and signed_tx (raw signed transaction)
+ :rtype: dict
+ """
+ session = SessionBase.create_session()
+ tx = session.query(Otx).filter(Otx.tx_hash==tx_hash).first()
+ if tx == None:
+ raise NotLocalTxError('queue does not contain tx hash {}'.format(tx_hash))
+
+ o = {
+ 'otx_id': tx.id,
+ 'nonce': tx.nonce,
+ 'signed_tx': tx.signed_tx,
+ 'status': tx.status,
+ }
+ logg.debug('get tx {}'.format(o))
+ session.close()
+ return o
+
+
+@celery_app.task()
+def get_nonce_tx(nonce, sender, chain_id):
+ """Retrieve all transactions for address with specified nonce
+
+ :param nonce: Nonce
+ :type nonce: number
+ :param address: Ethereum address
+ :type address: str, 0x-hex
+ :returns: Transactions
+ :rtype: dict, with transaction hash as key, signed raw transaction as value
+ """
+ session = SessionBase.create_session()
+ q = session.query(Otx)
+ q = q.join(TxCache)
+ q = q.filter(TxCache.sender==sender)
+ q = q.filter(Otx.nonce==nonce)
+
+ txs = {}
+ for r in q.all():
+ tx_signed_bytes = bytes.fromhex(r.signed_tx[2:])
+ tx = unpack_signed_raw_tx(tx_signed_bytes, chain_id)
+ if sender == None or tx['from'] == sender:
+ txs[r.tx_hash] = r.signed_tx
+
+ session.close()
+
+ return txs
+
+
+
+# TODO: pass chain spec instead of chain id
+def get_paused_txs(status=None, sender=None, chain_id=0):
+ """Returns not finalized transactions that have been attempted sent without success.
+
+ :param status: If set, will return transactions with this local queue status only
+ :type status: cic_eth.db.enum.StatusEnum
+ :param recipient: Recipient address to return transactions for
+ :type recipient: str, 0x-hex
+ :param chain_id: Numeric chain id to use to parse signed transaction data
+ :type chain_id: number
+ :raises ValueError: Status is finalized, sent or never attempted sent
+ :returns: Transactions
+ :rtype: dict, with transaction hash as key, signed raw transaction as value
+ """
+ session = SessionBase.create_session()
+ q = session.query(Otx)
+
+ if status != None:
+ if status == StatusEnum.PENDING or status >= StatusEnum.SENT:
+ raise ValueError('not a valid paused tx value: {}'.format(status))
+ q = q.filter(Otx.status==status)
+ q = q.join(TxCache)
+ else:
+ q = q.filter(Otx.status>StatusEnum.PENDING)
+ q = q.filter(Otx.status 0 and i == limit:
+ break
+ txs[o.tx_hash] = o.signed_tx
+ i += 1
+ session.close()
+ return txs
+
+
+# TODO: move query to model
+def get_upcoming_tx(status=StatusEnum.READYSEND, recipient=None, before=None, chain_id=0):
+ """Returns the next pending transaction, specifically the transaction with the lowest nonce, for every recipient that has pending transactions.
+
+ Will omit addresses that have the LockEnum.SEND bit in Lock set.
+
+ (TODO) Will not return any rows if LockEnum.SEND bit in Lock is set for zero address.
+
+ :param status: Defines the status used to filter as upcoming.
+ :type status: cic_eth.db.enum.StatusEnum
+ :param recipient: Ethereum address of recipient to return transaction for
+ :type recipient: str, 0x-hex
+ :param before: Only return transactions if their modification date is older than the given timestamp
+ :type before: datetime.datetime
+ :param chain_id: Chain id to use to parse signed transaction data
+ :type chain_id: number
+ :raises ValueError: Status is finalized, sent or never attempted sent
+ :returns: Transactions
+ :rtype: dict, with transaction hash as key, signed raw transaction as value
+ """
+ session = SessionBase.create_session()
+ q = session.query(
+ TxCache.sender,
+ func.min(Otx.nonce).label('nonce'),
+ )
+ q = q.join(TxCache)
+ q = q.join(Lock, isouter=True)
+ q = q.filter(or_(Lock.flags==None, Lock.flags.op('&')(LockEnum.SEND.value)==0))
+
+ if status >= StatusEnum.SENT:
+ raise ValueError('not a valid non-final tx value: {}'.format(s))
+ q = q.filter(Otx.status==status)
+
+ if recipient != None:
+ q = q.filter(TxCache.recipient==recipient)
+
+ q = q.group_by(TxCache.sender)
+
+ txs = {}
+
+ results = q.all()
+ for r in results:
+ q = session.query(Otx)
+ q = q.join(TxCache)
+ q = q.filter(TxCache.sender==r.sender)
+ q = q.filter(Otx.nonce==r.nonce)
+
+ if before != None:
+ q = q.filter(TxCache.date_checked 1:
+ task_queue = task_split[0]
+ task_pair = (task_split[1], task_queue)
+ transfer_callbacks.append(task_pair)
+
+
+# TODO: move to contract registry
+__convert_log_hash = '0x7154b38b5dd31bb3122436a96d4e09aba5b323ae1fd580025fab55074334c095' # keccak256(Conversion(address,address,address,uint256,uint256,address)
+__account_registry_add_log_hash = '0x5ed3bdd47b9af629827a8d129aa39c870b10c03f0153fe9ddb8e84b665061acd' # keccak256(AccountAdded(address,uint256))
+
+__transfer_method_signature = '0xa9059cbb' # keccak256(transfer(address,uint256))
+__transferfrom_method_signature = '0x23b872dd' # keccak256(transferFrom(address,address,uint256))
+__giveto_method_signature = '0x63e4bff4' # keccak256(giveTo(address))
+
+# TODO: move to bancor package
+def parse_convert_log(w3, entry):
+ data = entry.data[2:]
+ from_amount = int(data[:64], 16)
+ to_amount = int(data[64:128], 16)
+ holder_address_hex_raw = '0x' + data[-40:]
+ holder_address_hex = w3.toChecksumAddress(holder_address_hex_raw)
+ o = {
+ 'from_amount': from_amount,
+ 'to_amount': to_amount,
+ 'holder_address': holder_address_hex
+ }
+ logg.debug('parsed convert log {}'.format(o))
+ return o
+
+
+def registration_filter(w3, tx, rcpt, chain_spec):
+ registered_address = None
+ for l in rcpt['logs']:
+ event_topic_hex = l['topics'][0].hex()
+ if event_topic_hex == __account_registry_add_log_hash:
+ address_bytes = l.topics[1][32-20:]
+ address = web3.Web3.toChecksumAddress(address_bytes.hex())
+ logg.debug('request token gift to {}'.format(address))
+ s = celery.signature(
+ 'cic_eth.eth.account.gift',
+ [
+ address,
+ str(chain_spec),
+ ],
+ queue=queue,
+ )
+ s.apply_async()
+
+
+def convert_filter(w3, tx, rcpt, chain_spec):
+ destination_token_address = None
+ recipient_address = None
+ amount = 0
+ for l in rcpt['logs']:
+ event_topic_hex = l['topics'][0].hex()
+ if event_topic_hex == __convert_log_hash:
+ tx_hash_hex = tx['hash'].hex()
+ try:
+ convert_transfer = TxConvertTransfer.get(tx_hash_hex)
+ except UnknownConvertError:
+ logg.warning('skipping unknown convert tx {}'.format(tx_hash_hex))
+ continue
+ if convert_transfer.transfer_tx_hash != None:
+ logg.warning('convert tx {} cache record already has transfer hash {}, skipping'.format(tx_hash_hex, convert_transfer.transfer_hash))
+ continue
+ recipient_address = convert_transfer.recipient_address
+ logg.debug('found convert event {} recipient'.format(tx_hash_hex, recipient_address))
+ r = parse_convert_log(l)
+ destination_token_address = l['topics'][3][-20:]
+
+ if destination_token_address == zero_address or destination_token_address == None:
+ return None
+
+ destination_token_address_hex = destination_token_address.hex()
+ s = celery.signature(
+ 'cic_eth.eth.bancor.transfer_converted',
+ [
+ [{
+ 'address': w3.toChecksumAddress(destination_token_address_hex),
+ }],
+ r['holder_address'],
+ recipient_address,
+ r['to_amount'],
+ tx_hash_hex,
+ str(chain_spec),
+ ],
+ queue=queue,
+ )
+ logg.info('sending tx signature {}'.format(s))
+ t = s.apply_async()
+ logg.debug('submitted transfer after convert task uuid {} {}'.format(t, t.successful()))
+ return t
+
+
+def tx_filter(w3, tx, rcpt, chain_spec):
+ tx_hash_hex = tx.hash.hex()
+ otx = Otx.load(tx_hash_hex)
+ if otx == None:
+ logg.debug('tx {} not found locally, skipping'.format(tx_hash_hex))
+ return None
+ logg.info('otx found {}'.format(otx.tx_hash))
+ s = celery.signature(
+ 'cic_eth.queue.tx.set_final_status',
+ [
+ tx_hash_hex,
+ rcpt.blockNumber,
+ rcpt.status == 0,
+ ],
+ queue=queue,
+ )
+ t = s.apply_async()
+ return t
+
+
+# TODO: replace with registry call instead
+def get_token_symbol(w3, address):
+ #token = CICRegistry.get_address(CICRegistry.chain_spec, tx['to'])
+ logg.warning('token verification missing')
+ c = w3.eth.contract(abi=CICRegistry.abi('ERC20'), address=address)
+ return c.functions.symbol().call()
+
+
+# TODO: replace with registry call instead
+def get_token_decimals(w3, address):
+ #token = CICRegistry.get_address(CICRegistry.chain_spec, tx['to'])
+ logg.warning('token verification missing')
+ c = w3.eth.contract(abi=CICRegistry.abi('ERC20'), address=address)
+ return c.functions.decimals().call()
+
+
+def callbacks_filter(w3, tx, rcpt, chain_spec):
+ transfer_data = None
+ if len(tx.input) < 10:
+ logg.debug('callbacks filter data length not sufficient for method signature in tx {}, skipping'.format(tx['hash']))
+ return
+
+ logg.debug('checking callbacks filter input {}'.format(tx.input[:10]))
+
+ transfer_type = 'transfer'
+ method_signature = tx.input[:10]
+ if method_signature == __transfer_method_signature:
+ transfer_data = unpack_transfer(tx.input)
+ transfer_data['from'] = tx['from']
+ transfer_data['token_address'] = tx['to']
+ elif method_signature == __transferfrom_method_signature:
+ transfer_type = 'transferfrom'
+ transfer_data = unpack_transferfrom(tx.input)
+ transfer_data['token_address'] = tx['to']
+ elif method_signature == __giveto_method_signature:
+ transfer_type = 'tokengift'
+ transfer_data = unpack_gift(tx.input)
+ for l in rcpt.logs:
+ if l.topics[0].hex() == '0x45c201a59ac545000ead84f30b2db67da23353aa1d58ac522c48505412143ffa':
+ transfer_data['amount'] = web3.Web3.toInt(hexstr=l.data)
+ token_address_bytes = l.topics[2][32-20:]
+ transfer_data['token_address'] = web3.Web3.toChecksumAddress(token_address_bytes.hex())
+ transfer_data['from'] = rcpt.to
+
+ if transfer_data != None:
+ for tc in transfer_callbacks:
+ token_symbol = None
+ try:
+ logg.debug('checking token {}'.format(transfer_data['token_address']))
+ token_symbol = get_token_symbol(w3, transfer_data['token_address'])
+ token_decimals = get_token_decimals(w3, transfer_data['token_address'])
+ logg.debug('calling transfer callback {}:{} for tx {}'.format(tc[1], tc[0], tx['hash']))
+ except UnknownContractError:
+ logg.debug('callback filter {}:{} skipping "transfer" method on unknown contract {} tx {}'.format(tc[1], tc[0], transfer_data['to'], tx.hash.hex()))
+ continue
+ result = {
+ 'hash': tx.hash.hex(),
+ 'sender': transfer_data['from'],
+ 'recipient': transfer_data['to'],
+ 'source_value': transfer_data['amount'],
+ 'destination_value': transfer_data['amount'],
+ 'source_token': transfer_data['token_address'],
+ 'destination_token': transfer_data['token_address'],
+ 'source_token_symbol': token_symbol,
+ 'destination_token_symbol': token_symbol,
+ 'source_token_decimals': token_decimals,
+ 'destination_token_decimals': token_decimals,
+ 'chain': str(chain_spec),
+ }
+ s = celery.signature(
+ tc[0],
+ [
+ result,
+ transfer_type,
+ int(rcpt.status == 0),
+ ],
+ queue=tc[1],
+ )
+ s.apply_async()
+
+
+class GasFilter:
+
+ def __init__(self, gas_provider):
+ self.gas_provider = gas_provider
+
+ def filter(self, w3, tx, rcpt, chain_str):
+ tx_hash_hex = tx.hash.hex()
+ if tx['value'] > 0:
+ logg.debug('gas refill tx {}'.format(tx_hash_hex))
+ session = SessionBase.create_session()
+ q = session.query(TxCache.recipient)
+ q = q.join(Otx)
+ q = q.filter(Otx.tx_hash==tx_hash_hex)
+ r = q.first()
+
+ session.close()
+
+ if r == None:
+ logg.warning('unsolicited gas refill tx {}'.format(tx_hash_hex))
+ return
+
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ txs = get_paused_txs(StatusEnum.WAITFORGAS, r[0], chain_spec.chain_id())
+
+ if len(txs) > 0:
+ logg.info('resuming gas-in-waiting txs for {}: {}'.format(r[0], txs.keys()))
+ s = create_check_gas_and_send_task(
+ list(txs.values()),
+ str(chain_str),
+ r[0],
+ 0,
+ tx_hashes_hex=list(txs.keys()),
+ queue=queue,
+ )
+ s.apply_async()
+
+
+re_websocket = re.compile('^wss?://')
+re_http = re.compile('^https?://')
+blockchain_provider = config.get('ETH_PROVIDER')
+if re.match(re_websocket, blockchain_provider) != None:
+ blockchain_provider = WebsocketProvider(blockchain_provider)
+elif re.match(re_http, blockchain_provider) != None:
+ blockchain_provider = HTTPProvider(blockchain_provider)
+else:
+ raise ValueError('unknown provider url {}'.format(blockchain_provider))
+
+def web3_constructor():
+ w3 = web3.Web3(blockchain_provider)
+ return (blockchain_provider, w3)
+RpcClient.set_constructor(web3_constructor)
+
+
+def main():
+
+ chain_spec = ChainSpec.from_chain_str(config.get('CIC_CHAIN_SPEC'))
+ c = RpcClient(chain_spec)
+
+ CICRegistry.init(c.w3, config.get('CIC_REGISTRY_ADDRESS'), chain_spec)
+ CICRegistry.add_path(config.get('ETH_ABI_DIR'))
+ chain_registry = ChainRegistry(chain_spec)
+ CICRegistry.add_chain_registry(chain_registry)
+
+ if config.get('ETH_ACCOUNT_ACCOUNTS_INDEX_WRITER') != None:
+ CICRegistry.add_role(chain_spec, config.get('ETH_ACCOUNT_ACCOUNTS_INDEX_WRITER'), 'AccountRegistry', True)
+
+ syncers = []
+ block_offset = c.w3.eth.blockNumber
+ chain = str(chain_spec)
+
+ if SyncerBackend.first(chain):
+ from cic_eth.sync.history import HistorySyncer
+ backend = SyncerBackend.initial(chain, block_offset)
+ syncer = HistorySyncer(backend)
+ syncers.append(syncer)
+
+ if args.mode == 'head':
+ from cic_eth.sync.head import HeadSyncer
+ block_sync = SyncerBackend.live(chain, block_offset+1)
+ syncers.append(HeadSyncer(block_sync))
+ elif args.mode == 'history':
+ from cic_eth.sync.history import HistorySyncer
+ backends = SyncerBackend.resume(chain, block_offset+1)
+ for backend in backends:
+ syncers.append(HistorySyncer(backend))
+ if len(syncers) == 0:
+ logg.info('found no unsynced history. terminating')
+ sys.exit(0)
+ else:
+ sys.stderr.write("unknown mode '{}'\n".format(args.mode))
+ sys.exit(1)
+
+# bancor_registry_contract = CICRegistry.get_contract(chain_spec, 'BancorRegistry', interface='Registry')
+# bancor_chain_registry = CICRegistry.get_chain_registry(chain_spec)
+# bancor_registry = BancorRegistryClient(c.w3, bancor_chain_registry, config.get('ETH_ABI_DIR'))
+# bancor_registry.load()
+
+ i = 0
+ for syncer in syncers:
+ logg.debug('running syncer index {}'.format(i))
+ gas_filter = GasFilter(c.gas_provider()).filter
+ syncer.filter.append(gas_filter)
+ syncer.filter.append(registration_filter)
+ syncer.filter.append(callbacks_filter)
+ # TODO: the two following filter functions break the filter loop if return uuid. Pro: less code executed. Con: Possibly unintuitive flow break
+ syncer.filter.append(tx_filter)
+ syncer.filter.append(convert_filter)
+
+ try:
+ syncer.loop(int(config.get('SYNCER_LOOP_INTERVAL')))
+ except LoopDone as e:
+ sys.stderr.write("sync '{}' done at block {}\n".format(args.mode, e))
+
+ i += 1
+
+ sys.exit(0)
+
+
+if __name__ == '__main__':
+ main()
diff --git a/apps/cic-eth/cic_eth/runnable/retry.py b/apps/cic-eth/cic_eth/runnable/retry.py
new file mode 100644
index 00000000..b59f6d05
--- /dev/null
+++ b/apps/cic-eth/cic_eth/runnable/retry.py
@@ -0,0 +1,214 @@
+import os
+import sys
+import logging
+import argparse
+import re
+import datetime
+
+import web3
+import confini
+import celery
+from web3 import HTTPProvider, WebsocketProvider
+from cic_registry import CICRegistry
+from cic_registry.chain import ChainSpec
+
+from cic_eth.db import dsn_from_config
+from cic_eth.db import SessionBase
+from cic_eth.eth import RpcClient
+from cic_eth.sync.retry import RetrySyncer
+from cic_eth.queue.tx import get_status_tx
+from cic_eth.queue.tx import get_tx
+from cic_eth.admin.ctrl import lock_send
+from cic_eth.db.enum import StatusEnum
+from cic_eth.db.enum import LockEnum
+from cic_eth.eth.util import unpack_signed_raw_tx_hex
+
+logging.basicConfig(level=logging.WARNING)
+logg = logging.getLogger()
+logging.getLogger('websockets.protocol').setLevel(logging.CRITICAL)
+logging.getLogger('web3.RequestManager').setLevel(logging.CRITICAL)
+logging.getLogger('web3.providers.WebsocketProvider').setLevel(logging.CRITICAL)
+logging.getLogger('web3.providers.HTTPProvider').setLevel(logging.CRITICAL)
+
+
+config_dir = os.path.join('/usr/local/etc/cic-eth')
+
+argparser = argparse.ArgumentParser(description='daemon that monitors transactions in new blocks')
+argparser.add_argument('-c', type=str, default=config_dir, help='config root to use')
+argparser.add_argument('-i', '--chain-spec', dest='i', type=str, help='chain spec')
+argparser.add_argument('--retry-delay', dest='retry_delay', type=str, help='seconds to wait for retrying a transaction that is marked as sent')
+argparser.add_argument('--abi-dir', dest='abi_dir', type=str, help='Directory containing bytecode and abi')
+argparser.add_argument('--env-prefix', default=os.environ.get('CONFINI_ENV_PREFIX'), dest='env_prefix', type=str, help='environment prefix for variables to overwrite configuration')
+argparser.add_argument('-q', type=str, default='cic-eth', help='celery queue to submit transaction tasks to')
+argparser.add_argument('-v', help='be verbose', action='store_true')
+argparser.add_argument('-vv', help='be more verbose', action='store_true')
+args = argparser.parse_args(sys.argv[1:])
+
+
+if args.v == True:
+ logging.getLogger().setLevel(logging.INFO)
+elif args.vv == True:
+ logging.getLogger().setLevel(logging.DEBUG)
+
+config_dir = os.path.join(args.c)
+os.makedirs(config_dir, 0o777, True)
+config = confini.Config(config_dir, args.env_prefix)
+config.process()
+# override args
+args_override = {
+ 'ETH_ABI_DIR': getattr(args, 'abi_dir'),
+ 'CIC_CHAIN_SPEC': getattr(args, 'i'),
+ 'CIC_TX_RETRY_DELAY': getattr(args, 'retry_delay'),
+ }
+config.dict_override(args_override, 'cli flag')
+config.censor('PASSWORD', 'DATABASE')
+config.censor('PASSWORD', 'SSL')
+logg.debug('config loaded from {}:\n{}'.format(config_dir, config))
+
+app = celery.Celery(backend=config.get('CELERY_RESULT_URL'), broker=config.get('CELERY_BROKER_URL'))
+
+queue = args.q
+
+chain_spec = ChainSpec.from_chain_str(config.get('CIC_CHAIN_SPEC'))
+
+dsn = dsn_from_config(config)
+SessionBase.connect(dsn)
+
+
+re_websocket = re.compile('^wss?://')
+re_http = re.compile('^https?://')
+blockchain_provider = config.get('ETH_PROVIDER')
+if re.match(re_websocket, blockchain_provider) != None:
+ blockchain_provider = WebsocketProvider(blockchain_provider)
+elif re.match(re_http, blockchain_provider) != None:
+ blockchain_provider = HTTPProvider(blockchain_provider)
+else:
+ raise ValueError('unknown provider url {}'.format(blockchain_provider))
+
+def web3_constructor():
+ w3 = web3.Web3(blockchain_provider)
+ return (blockchain_provider, w3)
+RpcClient.set_constructor(web3_constructor)
+
+
+straggler_delay = int(config.get('CIC_TX_RETRY_DELAY'))
+
+# TODO: we already have the signed raw tx in get, so its a waste of cycles to get_tx here
+def sendfail_filter(w3, tx_hash, rcpt, chain_str):
+ chain_spec = ChainSpec.from_chain_str(chain_str)
+ tx_dict = get_tx(tx_hash)
+ tx = unpack_signed_raw_tx_hex(tx_dict['signed_tx'], chain_spec.chain_id())
+ logg.debug('submitting tx {} for retry'.format(tx_hash))
+ s_check = celery.signature(
+ 'cic_eth.admin.ctrl.check_lock',
+ [
+ tx_hash,
+ chain_str,
+ LockEnum.QUEUE,
+ tx['from'],
+ ],
+ queue=queue,
+ )
+# s_resume = celery.signature(
+# 'cic_eth.eth.tx.resume_tx',
+# [
+# chain_str,
+# ],
+# queue=queue,
+# )
+
+# s_retry_status = celery.signature(
+# 'cic_eth.queue.tx.set_ready',
+# [],
+# queue=queue,
+# )
+ s_resend = celery.signature(
+ 'cic_eth.eth.tx.resend_with_higher_gas',
+ [
+ chain_str,
+ ],
+ queue=queue,
+ )
+
+ #s_resume.link(s_retry_status)
+ #s_check.link(s_resume)
+ s_check.link(s_resend)
+ s_check.apply_async()
+
+
+# TODO: can we merely use the dispatcher instead?
+def dispatch(chain_str):
+ txs = get_status_tx(StatusEnum.RETRY, datetime.datetime.utcnow())
+ if len(txs) == 0:
+ logg.debug('no retry state txs found')
+ return
+ #signed_txs = list(txs.values())
+ #logg.debug('signed txs {} chain {}'.format(signed_txs, chain_str))
+ #for tx in signed_txs:
+ for k in txs.keys():
+ #tx_cache = get_tx_cache(k)
+ tx_raw = txs[k]
+ tx = unpack_signed_raw_tx_hex(tx_raw, chain_spec.chain_id())
+
+ s_check = celery.signature(
+ 'cic_eth.admin.ctrl.check_lock',
+ [
+ [tx_raw],
+ chain_str,
+ LockEnum.QUEUE,
+ tx['from'],
+ ],
+ queue=queue,
+ )
+ s_send = celery.signature(
+ 'cic_eth.eth.tx.send',
+ [
+ chain_str,
+ ],
+ queue=queue,
+ )
+ s_check.link(s_send)
+ t = s_check.apply_async()
+
+# try:
+# r = t.get()
+# logg.debug('submitted as {} result {} with queue task {}'.format(t, r, t.children[0].get()))
+# except PermanentTxError as e:
+# logg.error('tx {} permanently failed: {}'.format(tx, e))
+# except TemporaryTxError as e:
+# logg.error('tx {} temporarily failed: {}'.format(tx, e))
+
+#
+#
+#def straggler_filter(w3, tx, rcpt, chain_str):
+# before = datetime.datetime.utcnow() - datetime.timedelta(seconds=straggler_delay)
+# txs = get_status_tx(StatusEnum.SENT, before)
+# if len(txs) == 0:
+# logg.debug('no straggler txs found')
+# return
+# txs = list(txs.keys())
+# logg.debug('straggler txs {} chain {}'.format(signed_txs, chain_str))
+# s_send = celery.signature(
+# 'cic_eth.eth.resend_with_higher_gas',
+# [
+# txs,
+# chain_str,
+# ],
+# queue=queue,
+# )
+# s_send.apply_async()
+
+
+def main():
+
+ c = RpcClient(chain_spec)
+ CICRegistry.init(c.w3, config.get('CIC_REGISTRY_ADDRESS'), chain_spec)
+ CICRegistry.add_path(config.get('ETH_ABI_DIR'))
+
+ syncer = RetrySyncer(chain_spec, straggler_delay, final_func=dispatch)
+ syncer.filter.append(sendfail_filter)
+ syncer.loop(float(straggler_delay))
+
+
+if __name__ == '__main__':
+ main()
diff --git a/apps/cic-eth/cic_eth/runnable/server_agent.py b/apps/cic-eth/cic_eth/runnable/server_agent.py
new file mode 100644
index 00000000..5f89f12d
--- /dev/null
+++ b/apps/cic-eth/cic_eth/runnable/server_agent.py
@@ -0,0 +1,173 @@
+# standard imports
+import os
+import re
+import logging
+import argparse
+import json
+
+# third-party imports
+import web3
+import confini
+import celery
+from json.decoder import JSONDecodeError
+from cic_registry.chain import ChainSpec
+
+# local imports
+from cic_eth.db import dsn_from_config
+from cic_eth.db.models.base import SessionBase
+from cic_eth.eth.util import unpack_signed_raw_tx
+
+logging.basicConfig(level=logging.WARNING)
+logg = logging.getLogger()
+
+rootdir = os.path.dirname(os.path.dirname(os.path.realpath(__file__)))
+dbdir = os.path.join(rootdir, 'cic_eth', 'db')
+migrationsdir = os.path.join(dbdir, 'migrations')
+
+config_dir = os.path.join('/usr/local/etc/cic-eth')
+
+argparser = argparse.ArgumentParser()
+argparser.add_argument('-c', type=str, default=config_dir, help='config file')
+argparser.add_argument('-i', '--chain-spec', dest='i', type=str, help='chain spec')
+argparser.add_argument('--env-prefix', default=os.environ.get('CONFINI_ENV_PREFIX'), dest='env_prefix', type=str, help='environment prefix for variables to overwrite configuration')
+argparser.add_argument('-q', type=str, default='cic-eth', help='queue name for worker tasks')
+argparser.add_argument('-v', action='store_true', help='be verbose')
+argparser.add_argument('-vv', action='store_true', help='be more verbose')
+args = argparser.parse_args()
+
+if args.vv:
+ logging.getLogger().setLevel(logging.DEBUG)
+elif args.v:
+ logging.getLogger().setLevel(logging.INFO)
+
+config = confini.Config(args.c, args.env_prefix)
+config.process()
+args_override = {
+ 'CIC_CHAIN_SPEC': getattr(args, 'i'),
+ }
+config.censor('PASSWORD', 'DATABASE')
+config.censor('PASSWORD', 'SSL')
+logg.debug('config:\n{}'.format(config))
+
+dsn = dsn_from_config(config)
+SessionBase.connect(dsn)
+
+celery_app = celery.Celery(backend=config.get('CELERY_RESULT_URL'), broker=config.get('CELERY_BROKER_URL'))
+queue = args.q
+
+re_transfer_approval_request = r'^/transferrequest/?'
+
+chain_spec = ChainSpec.from_chain_str(config.get('CIC_CHAIN_SPEC'))
+
+
+def process_transfer_approval_request(session, env):
+ r = re.match(re_transfer_approval_request, env.get('PATH_INFO'))
+ if not r:
+ return None
+
+ if env.get('CONTENT_TYPE') != 'application/json':
+ raise AttributeError('content type')
+
+ if env.get('REQUEST_METHOD') != 'POST':
+ raise AttributeError('method')
+
+ post_data = json.load(env.get('wsgi.input'))
+ token_address = web3.Web3.toChecksumAddress(post_data['token_address'])
+ holder_address = web3.Web3.toChecksumAddress(post_data['holder_address'])
+ beneficiary_address = web3.Web3.toChecksumAddress(post_data['beneficiary_address'])
+ value = int(post_data['value'])
+
+ logg.debug('transfer approval request token {} to {} from {} value {}'.format(
+ token_address,
+ beneficiary_address,
+ holder_address,
+ value,
+ )
+ )
+
+ s = celery.signature(
+ 'cic_eth.eth.request.transfer_approval_request',
+ [
+ [
+ {
+ 'address': token_address,
+ },
+ ],
+ holder_address,
+ beneficiary_address,
+ value,
+ config.get('CIC_CHAIN_SPEC'),
+ ],
+ queue=queue,
+ )
+ t = s.apply_async()
+ r = t.get()
+ tx_raw_bytes = bytes.fromhex(r[0][2:])
+ tx = unpack_signed_raw_tx(tx_raw_bytes, chain_spec.chain_id())
+ for r in t.collect():
+ logg.debug('result {}'.format(r))
+
+ if not t.successful():
+ raise RuntimeError(tx['hash'])
+
+ return ('text/plain', tx['hash'].encode('utf-8'),)
+
+
+# uwsgi application
+def application(env, start_response):
+
+ for k in env.keys():
+ logg.debug('env {} {}'.format(k, env[k]))
+
+ headers = []
+ content = b''
+ err = None
+
+ session = SessionBase.create_session()
+ for handler in [
+ process_transfer_approval_request,
+ ]:
+ try:
+ r = handler(session, env)
+ except AttributeError as e:
+ logg.error('handler fail attribute {}'.format(e))
+ err = '400 Impertinent request'
+ break
+ except JSONDecodeError as e:
+ logg.error('handler fail json {}'.format(e))
+ err = '400 Invalid data format'
+ break
+ except KeyError as e:
+ logg.error('handler fail key {}'.format(e))
+ err = '400 Invalid JSON'
+ break
+ except ValueError as e:
+ logg.error('handler fail value {}'.format(e))
+ err = '400 Invalid data'
+ break
+ except RuntimeError as e:
+ logg.error('task fail value {}'.format(e))
+ err = '500 Task failed, sorry I cannot tell you more'
+ break
+ if r != None:
+ (mime_type, content) = r
+ break
+ session.close()
+
+ if err != None:
+ headers.append(('Content-Type', 'text/plain, charset=UTF-8',))
+ start_response(err, headers)
+ session.close()
+ return [content]
+
+ headers.append(('Content-Length', str(len(content))),)
+ headers.append(('Access-Control-Allow-Origin', '*',));
+
+ if len(content) == 0:
+ headers.append(('Content-Type', 'text/plain, charset=UTF-8',))
+ start_response('404 Looked everywhere, sorry', headers)
+ else:
+ headers.append(('Content-Type', mime_type,))
+ start_response('200 OK', headers)
+
+ return [content]
diff --git a/apps/cic-eth/cic_eth/runnable/tag.py b/apps/cic-eth/cic_eth/runnable/tag.py
new file mode 100644
index 00000000..c1df1e30
--- /dev/null
+++ b/apps/cic-eth/cic_eth/runnable/tag.py
@@ -0,0 +1,77 @@
+# standard imports
+import os
+import sys
+import logging
+import argparse
+import re
+
+# third-party imports
+import web3
+from web3 import HTTPProvider, WebsocketProvider
+import confini
+
+# local imports
+from cic_eth.api import AdminApi
+from cic_eth.eth import RpcClient
+from cic_eth.db import dsn_from_config
+from cic_eth.db.models.base import SessionBase
+
+logging.basicConfig(level=logging.WARNING)
+logg = logging.getLogger()
+
+default_config_dir = os.environ.get('CONFINI_DIR', '/usr/local/etc/cic')
+
+
+argparser = argparse.ArgumentParser(description='daemon that monitors transactions in new blocks')
+argparser.add_argument('-p', '--provider', dest='p', type=str, help='Web3 provider url (http only)')
+argparser.add_argument('-c', type=str, default=default_config_dir, help='config root to use')
+argparser.add_argument('-v', help='be verbose', action='store_true')
+argparser.add_argument('-i', '--chain-spec', dest='i', type=str, help='chain spec')
+argparser.add_argument('-vv', help='be more verbose', action='store_true')
+argparser.add_argument('tag', type=str, help='address tag')
+argparser.add_argument('address', type=str, help='address')
+args = argparser.parse_args(sys.argv[1:])
+
+if args.v == True:
+ logging.getLogger().setLevel(logging.INFO)
+elif args.vv == True:
+ logging.getLogger().setLevel(logging.DEBUG)
+
+config = confini.Config(args.c)
+config.process()
+args_override = {
+ 'ETH_PROVIDER': getattr(args, 'p'),
+ 'CIC_CHAIN_SPEC': getattr(args, 'i'),
+ }
+config.dict_override(args_override, 'cli flag')
+config.censor('PASSWORD', 'DATABASE')
+config.censor('PASSWORD', 'SSL')
+logg.debug('config loaded from {}\n{}'.format(args.c, config))
+
+
+dsn = dsn_from_config(config)
+SessionBase.connect(dsn)
+
+re_websocket = re.compile('^wss?://')
+re_http = re.compile('^https?://')
+blockchain_provider = config.get('ETH_PROVIDER')
+if re.match(re_websocket, blockchain_provider) != None:
+ blockchain_provider = WebsocketProvider(blockchain_provider)
+elif re.match(re_http, blockchain_provider) != None:
+ blockchain_provider = HTTPProvider(blockchain_provider)
+else:
+ raise ValueError('unknown provider url {}'.format(blockchain_provider))
+
+def web3_constructor():
+ w3 = web3.Web3(blockchain_provider)
+ return (blockchain_provider, w3)
+RpcClient.set_constructor(web3_constructor)
+c = RpcClient(config.get('CIC_CHAIN_SPEC'))
+
+def main():
+ api = AdminApi(c)
+ api.tag_account(args.tag, args.address)
+
+
+if __name__ == '__main__':
+ main()
diff --git a/apps/cic-eth/cic_eth/runnable/tasker.py b/apps/cic-eth/cic_eth/runnable/tasker.py
new file mode 100644
index 00000000..efbb6e75
--- /dev/null
+++ b/apps/cic-eth/cic_eth/runnable/tasker.py
@@ -0,0 +1,238 @@
+# standard imports
+import sys
+import os
+import logging
+import argparse
+import tempfile
+import re
+import urllib
+import websocket
+
+# third-party imports
+import celery
+import confini
+from crypto_dev_signer.eth.web3ext import Web3 as Web3Ext
+from web3 import HTTPProvider, WebsocketProvider
+from gas_proxy.web3 import GasMiddleware
+
+# local imports
+from cic_registry.registry import CICRegistry
+from cic_registry.registry import ChainRegistry
+from cic_registry.registry import ChainSpec
+from cic_registry.helper.declarator import DeclaratorOracleAdapter
+
+from cic_bancor.bancor import BancorRegistryClient
+from cic_eth.eth import bancor
+from cic_eth.eth import token
+from cic_eth.eth import tx
+from cic_eth.eth import account
+from cic_eth.eth import request
+from cic_eth.admin import debug
+from cic_eth.admin import ctrl
+from cic_eth.eth.rpc import RpcClient
+from cic_eth.eth.rpc import GasOracle
+from cic_eth.queue import tx
+from cic_eth.callbacks import Callback
+from cic_eth.callbacks import http
+from cic_eth.callbacks import tcp
+from cic_eth.callbacks import redis
+from cic_eth.db.models.base import SessionBase
+from cic_eth.db.models.otx import Otx
+from cic_eth.db import dsn_from_config
+
+logging.basicConfig(level=logging.WARNING)
+logg = logging.getLogger()
+
+config_dir = os.path.join('/usr/local/etc/cic-eth')
+
+argparser = argparse.ArgumentParser()
+argparser.add_argument('-p', '--provider', dest='p', type=str, help='web3 provider')
+argparser.add_argument('-c', type=str, default=config_dir, help='config file')
+argparser.add_argument('-q', type=str, default='cic-eth', help='queue name for worker tasks')
+argparser.add_argument('--abi-dir', dest='abi_dir', type=str, help='Directory containing bytecode and abi')
+argparser.add_argument('--trace-queue-status', default=None, dest='trace_queue_status', action='store_true', help='set to perist all queue entry status changes to storage')
+argparser.add_argument('-i', '--chain-spec', dest='i', type=str, help='chain spec')
+argparser.add_argument('--env-prefix', default=os.environ.get('CONFINI_ENV_PREFIX'), dest='env_prefix', type=str, help='environment prefix for variables to overwrite configuration')
+argparser.add_argument('-v', action='store_true', help='be verbose')
+argparser.add_argument('-vv', action='store_true', help='be more verbose')
+args = argparser.parse_args()
+
+if args.vv:
+ logging.getLogger().setLevel(logging.DEBUG)
+elif args.v:
+ logging.getLogger().setLevel(logging.INFO)
+
+config = confini.Config(args.c, args.env_prefix)
+config.process()
+# override args
+args_override = {
+ 'ETH_ABI_DIR': getattr(args, 'abi_dir'),
+ 'CIC_CHAIN_SPEC': getattr(args, 'i'),
+ 'ETH_PROVIDER': getattr(args, 'p'),
+ 'TASKS_TRACE_QUEUE_STATUS': getattr(args, 'trace_queue_status'),
+ }
+config.dict_override(args_override, 'cli flag')
+config.censor('PASSWORD', 'DATABASE')
+config.censor('PASSWORD', 'SSL')
+logg.debug('config loaded from {}:\n{}'.format(args.c, config))
+
+# connect to database
+dsn = dsn_from_config(config)
+SessionBase.connect(dsn)
+
+# verify database connection with minimal sanity query
+session = SessionBase.create_session()
+session.execute('select version_num from alembic_version')
+session.close()
+
+# set up celery
+current_app = celery.Celery(__name__)
+
+broker = config.get('CELERY_BROKER_URL')
+if broker[:4] == 'file':
+ bq = tempfile.mkdtemp()
+ bp = tempfile.mkdtemp()
+ current_app.conf.update({
+ 'broker_url': broker,
+ 'broker_transport_options': {
+ 'data_folder_in': bq,
+ 'data_folder_out': bq,
+ 'data_folder_processed': bp,
+ },
+ },
+ )
+ logg.warning('celery broker dirs queue i/o {} processed {}, will NOT be deleted on shutdown'.format(bq, bp))
+else:
+ current_app.conf.update({
+ 'broker_url': broker,
+ })
+
+result = config.get('CELERY_RESULT_URL')
+if result[:4] == 'file':
+ rq = tempfile.mkdtemp()
+ current_app.conf.update({
+ 'result_backend': 'file://{}'.format(rq),
+ })
+ logg.warning('celery backend store dir {} created, will NOT be deleted on shutdown'.format(rq))
+else:
+ current_app.conf.update({
+ 'result_backend': result,
+ })
+
+
+# set up web3
+# TODO: web3 socket wrapping is now a lot of code. factor out
+class JSONRPCHttpSocketAdapter:
+
+ def __init__(self, url):
+ self.response = None
+ self.url = url
+
+ def send(self, data):
+ logg.debug('redirecting socket send to jsonrpc http socket adapter {} {}'.format(self.url, data))
+ req = urllib.request.Request(self.url, method='POST')
+ req.add_header('Content-type', 'application/json')
+ req.add_header('Connection', 'close')
+ res = urllib.request.urlopen(req, data=data.encode('utf-8'))
+ self.response = res.read().decode('utf-8')
+ logg.debug('setting jsonrpc http socket adapter response to {}'.format(self.response))
+
+ def recv(self, n=0):
+ return self.response
+
+
+re_websocket = re.compile('^wss?://')
+re_http = re.compile('^https?://')
+blockchain_provider = config.get('ETH_PROVIDER')
+socket_constructor = None
+if re.match(re_websocket, blockchain_provider) != None:
+ def socket_constructor_ws():
+ return websocket.create_connection(config.get('ETH_PROVIDER'))
+ socket_constructor = socket_constructor_ws
+ blockchain_provider = WebsocketProvider(blockchain_provider)
+elif re.match(re_http, blockchain_provider) != None:
+ def socket_constructor_http():
+ return JSONRPCHttpSocketAdapter(config.get('ETH_PROVIDER'))
+ socket_constructor = socket_constructor_http
+ blockchain_provider = HTTPProvider(blockchain_provider)
+else:
+ raise ValueError('unknown provider url {}'.format(blockchain_provider))
+
+
+def web3ext_constructor():
+ w3 = Web3Ext(blockchain_provider, config.get('SIGNER_SOCKET_PATH'))
+ GasMiddleware.socket_constructor = socket_constructor
+ w3.middleware_onion.add(GasMiddleware)
+
+ def sign_transaction(tx):
+ r = w3.eth.signTransaction(tx)
+ d = r.__dict__
+ for k in d.keys():
+ if k == 'tx':
+ d[k] = d[k].__dict__
+ else:
+ d[k] = d[k].hex()
+ return d
+
+ setattr(w3.eth, 'sign_transaction', sign_transaction)
+ setattr(w3.eth, 'send_raw_transaction', w3.eth.sendRawTransaction)
+ return (blockchain_provider, w3)
+RpcClient.set_constructor(web3ext_constructor)
+
+logg.info('ccc {}'.format(config.store['TASKS_TRACE_QUEUE_STATUS']))
+Otx.tracing = config.true('TASKS_TRACE_QUEUE_STATUS')
+
+
+def main():
+ argv = ['worker']
+ if args.vv:
+ argv.append('--loglevel=DEBUG')
+ elif args.v:
+ argv.append('--loglevel=INFO')
+ argv.append('-Q')
+ argv.append(args.q)
+ argv.append('-n')
+ argv.append(args.q)
+
+ if config.true('SSL_ENABLE_CLIENT'):
+ Callback.ssl = True
+ Callback.ssl_cert_file = config.get('SSL_CERT_FILE')
+ Callback.ssl_key_file = config.get('SSL_KEY_FILE')
+ Callback.ssl_password = config.get('SSL_PASSWORD')
+
+ if config.get('SSL_CA_FILE') != '':
+ Callback.ssl_ca_file = config.get('SSL_CA_FILE')
+
+ chain_spec = ChainSpec.from_chain_str(config.get('CIC_CHAIN_SPEC'))
+
+ c = RpcClient(chain_spec)
+ CICRegistry.init(c.w3, config.get('CIC_REGISTRY_ADDRESS'), chain_spec)
+ CICRegistry.add_path(config.get('ETH_ABI_DIR'))
+
+ chain_registry = ChainRegistry(chain_spec)
+ CICRegistry.add_chain_registry(chain_registry, True)
+
+ if config.get('ETH_ACCOUNT_ACCOUNTS_INDEX_WRITER') != None:
+ CICRegistry.add_role(chain_spec, config.get('ETH_ACCOUNT_ACCOUNTS_INDEX_WRITER'), 'AccountRegistry', True)
+
+ if config.get('CIC_DECLARATOR_ADDRESS') != None:
+ abi_path = os.path.join(config.get('ETH_ABI_DIR'), '{}.json'.format(interface))
+ f = open(abi_path)
+ abi = json.load(abi_path)
+ f.close()
+ c = w3.eth.contract(abi=abi, address=address)
+ trusted_addresses = config.get('CIC_TRUSTED_ADDRESSES', []).split(',')
+ oracle = DeclaratorOracleAdapter(contract, trusted_addresses)
+ chain_registry.add_oracle(oracle)
+
+
+ #chain_spec = CICRegistry.default_chain_spec
+ #bancor_registry_contract = CICRegistry.get_contract(chain_spec, 'BancorRegistry', interface='Registry')
+ #bancor_chain_registry = CICRegistry.get_chain_registry(chain_spec)
+ #bancor_registry = BancorRegistryClient(c.w3, bancor_chain_registry, config.get('ETH_ABI_DIR'))
+ #bancor_registry.load(True)
+ current_app.worker_main(argv)
+
+
+if __name__ == '__main__':
+ main()
diff --git a/apps/cic-eth/cic_eth/runnable/view.py b/apps/cic-eth/cic_eth/runnable/view.py
new file mode 100644
index 00000000..12de34eb
--- /dev/null
+++ b/apps/cic-eth/cic_eth/runnable/view.py
@@ -0,0 +1,177 @@
+#!python3
+
+# SPDX-License-Identifier: GPL-3.0-or-later
+
+# standard imports
+import os
+import json
+import argparse
+import logging
+import sys
+import re
+import datetime
+
+# third-party imports
+import confini
+import celery
+import web3
+from cic_registry import CICRegistry
+from cic_registry.chain import ChainSpec
+from cic_registry.chain import ChainRegistry
+
+# local imports
+from cic_eth.api import AdminApi
+from cic_eth.eth.rpc import RpcClient
+from cic_eth.db.enum import StatusEnum
+from cic_eth.db.enum import LockEnum
+
+logging.basicConfig(level=logging.WARNING)
+logg = logging.getLogger()
+
+logging.getLogger('web3').setLevel(logging.WARNING)
+logging.getLogger('urllib3').setLevel(logging.WARNING)
+
+
+default_abi_dir = '/usr/share/local/cic/solidity/abi'
+default_config_dir = os.path.join('/usr/local/etc/cic-eth')
+
+argparser = argparse.ArgumentParser()
+argparser.add_argument('-p', '--provider', dest='p', default='http://localhost:8545', type=str, help='Web3 provider url (http only)')
+argparser.add_argument('-r', '--registry-address', type=str, help='CIC registry address')
+argparser.add_argument('-f', '--format', dest='f', default='terminal', type=str, help='Output format')
+argparser.add_argument('-c', type=str, default=default_config_dir, help='config root to use')
+argparser.add_argument('-i', '--chain-spec', dest='i', type=str, help='chain spec')
+argparser.add_argument('-q', type=str, default='cic-eth', help='celery queue to submit transaction tasks to')
+argparser.add_argument('--env-prefix', default=os.environ.get('CONFINI_ENV_PREFIX'), dest='env_prefix', type=str, help='environment prefix for variables to overwrite configuration')
+argparser.add_argument('-v', action='store_true', help='Be verbose')
+argparser.add_argument('-vv', help='be more verbose', action='store_true')
+argparser.add_argument('query', type=str, help='Transaction, transaction hash, account or "lock"')
+args = argparser.parse_args()
+
+if args.v == True:
+ logging.getLogger().setLevel(logging.INFO)
+elif args.vv == True:
+ logging.getLogger().setLevel(logging.DEBUG)
+
+
+config_dir = os.path.join(args.c)
+os.makedirs(config_dir, 0o777, True)
+config = confini.Config(config_dir, args.env_prefix)
+config.process()
+args_override = {
+ 'ETH_PROVIDER': getattr(args, 'p'),
+ 'CIC_CHAIN_SPEC': getattr(args, 'i'),
+ }
+# override args
+config.censor('PASSWORD', 'DATABASE')
+config.censor('PASSWORD', 'SSL')
+logg.debug('config loaded from {}:\n{}'.format(config_dir, config))
+
+re_websocket = re.compile('^wss?://')
+re_http = re.compile('^https?://')
+blockchain_provider = config.get('ETH_PROVIDER')
+if re.match(re_websocket, blockchain_provider) != None:
+ blockchain_provider = web3.Web3.WebsocketProvider(blockchain_provider)
+elif re.match(re_http, blockchain_provider) != None:
+ blockchain_provider = web3.Web3.HTTPProvider(blockchain_provider)
+else:
+ raise ValueError('unknown provider url {}'.format(blockchain_provider))
+
+def web3_constructor():
+ w3 = web3.Web3(blockchain_provider)
+ return (blockchain_provider, w3)
+RpcClient.set_constructor(web3_constructor)
+
+
+celery_app = celery.Celery(broker=config.get('CELERY_BROKER_URL'), backend=config.get('CELERY_RESULT_URL'))
+
+queue = args.q
+
+chain_spec = ChainSpec.from_chain_str(config.get('CIC_CHAIN_SPEC'))
+chain_str = str(chain_spec)
+c = RpcClient(chain_spec)
+admin_api = AdminApi(c)
+
+CICRegistry.init(c.w3, config.get('CIC_REGISTRY_ADDRESS'), chain_spec)
+chain_registry = ChainRegistry(chain_spec)
+CICRegistry.add_chain_registry(chain_registry)
+CICRegistry.add_path(config.get('ETH_ABI_DIR'))
+CICRegistry.load_for(chain_spec)
+
+fmt = 'terminal'
+if args.f[:1] == 'j':
+ fmt = 'json'
+elif args.f[:1] != 't':
+ raise ValueError('unknown output format {}'.format(args.f))
+
+
+def render_tx(o, **kwargs):
+ content = ''
+ for k in o.keys():
+ if not k in ['status_log']:
+ content += '{}: {}\n'.format(k, o[k])
+ content += 'status log:\n'
+
+ for v in o.get('status_log', []):
+ d = datetime.datetime.fromisoformat(v[0])
+ e = StatusEnum(v[1]).name
+ content += '{}: {}\n'.format(d, e)
+
+ return content
+
+def render_account(o, **kwargs):
+ return '{} {} {} {}'.format(
+ o['date_updated'],
+ o['nonce'],
+ o['tx_hash'],
+ o['status'],
+ )
+
+
+def render_lock(o, **kwargs):
+ lockstrings = []
+ flags = o['flags']
+ for i in range(31):
+ v = 1 << i
+ if flags & v:
+ lockstrings.append(LockEnum(v).name)
+
+ s = '{} {} {}'.format(
+ o['address'],
+ o['date'],
+ ",".join(lockstrings),
+ )
+ if o['tx_hash'] != None:
+ s += ' ' + o['tx_hash']
+
+ return s
+
+# TODO: move each command to submodule
+def main():
+ logg.debug('len {}'.format(len(args.query)))
+ txs = []
+ renderer = render_tx
+ if len(args.query) > 66:
+ txs = [admin_api.tx(chain_spec, tx_raw=args.query)]
+ elif len(args.query) > 42:
+ txs = [admin_api.tx(chain_spec, tx_hash=args.query)]
+ elif len(args.query) == 42:
+ txs = admin_api.account(chain_spec, args.query, include_recipient=False)
+ renderer = render_account
+ elif len(args.query) >= 4 and args.query[:4] == 'lock':
+ txs = admin_api.get_lock()
+ renderer = render_lock
+ else:
+ raise ValueError('cannot parse argument {}'.format(args.query))
+
+ if len(txs) == 0:
+ logg.info('no matches found')
+ else:
+ if fmt == 'json':
+ sys.stdout.write(json.dumps(txs))
+ else:
+ m = map(renderer, txs)
+ print(*m, sep="\n")
+
+if __name__ == '__main__':
+ main()
diff --git a/apps/cic-eth/cic_eth/sync/__init__.py b/apps/cic-eth/cic_eth/sync/__init__.py
new file mode 100644
index 00000000..325f58dc
--- /dev/null
+++ b/apps/cic-eth/cic_eth/sync/__init__.py
@@ -0,0 +1 @@
+from .base import Syncer
diff --git a/apps/cic-eth/cic_eth/sync/backend.py b/apps/cic-eth/cic_eth/sync/backend.py
new file mode 100644
index 00000000..af58be94
--- /dev/null
+++ b/apps/cic-eth/cic_eth/sync/backend.py
@@ -0,0 +1,196 @@
+# standard imports
+import logging
+
+# local imports
+from cic_eth.db.models.sync import BlockchainSync
+from cic_eth.db.models.base import SessionBase
+
+logg = logging.getLogger()
+
+
+class SyncerBackend:
+ """Interface to block and transaction sync state.
+
+ :param chain_spec: Chain spec for the chain that syncer is running for.
+ :type chain_spec: cic_registry.chain.ChainSpec
+ :param object_id: Unique id for the syncer session.
+ :type object_id: number
+ """
+ def __init__(self, chain_spec, object_id):
+ self.db_session = None
+ self.db_object = None
+ self.chain_spec = chain_spec
+ self.object_id = object_id
+ self.connect()
+ self.disconnect()
+
+
+ def connect(self):
+ """Loads the state of the syncer session with the given id.
+ """
+ self.db_session = SessionBase.create_session()
+ q = self.db_session.query(BlockchainSync)
+ q = q.filter(BlockchainSync.id==self.object_id)
+ self.db_object = q.first()
+ if self.db_object == None:
+ raise ValueError('sync entry with id {} not found'.format(self.object_id))
+
+
+ def disconnect(self):
+ """Commits state of sync to backend.
+ """
+ self.db_session.add(self.db_object)
+ self.db_session.commit()
+ self.db_session.close()
+
+
+ def chain(self):
+ """Returns chain spec for syncer
+
+ :returns: Chain spec
+ :rtype chain_spec: cic_registry.chain.ChainSpec
+ """
+ return self.chain_spec
+
+
+ def get(self):
+ """Get the current state of the syncer cursor.
+
+ :returns: Block and block transaction height, respectively
+ :rtype: tuple
+ """
+ self.connect()
+ pair = self.db_object.cursor()
+ self.disconnect()
+ return pair
+
+
+ def set(self, block_height, tx_height):
+ """Update the state of the syncer cursor
+ :param block_height: Block height of cursor
+ :type block_height: number
+ :param tx_height: Block transaction height of cursor
+ :type tx_height: number
+ :returns: Block and block transaction height, respectively
+ :rtype: tuple
+ """
+ self.connect()
+ pair = self.db_object.set(block_height, tx_height)
+ self.disconnect()
+ return pair
+
+
+ def start(self):
+ """Get the initial state of the syncer cursor.
+
+ :returns: Initial block and block transaction height, respectively
+ :rtype: tuple
+ """
+ self.connect()
+ pair = self.db_object.start()
+ self.disconnect()
+ return pair
+
+
+ def target(self):
+ """Get the target state (upper bound of sync) of the syncer cursor.
+
+ :returns: Target block height
+ :rtype: number
+ """
+ self.connect()
+ target = self.db_object.target()
+ self.disconnect()
+ return target
+
+
+ @staticmethod
+ def first(chain):
+ """Returns the model object of the most recent syncer in backend.
+
+ :param chain: Chain spec of chain that syncer is running for.
+ :type chain: cic_registry.chain.ChainSpec
+ :returns: Last syncer object
+ :rtype: cic_eth.db.models.BlockchainSync
+ """
+ return BlockchainSync.first(chain)
+
+
+ @staticmethod
+ def initial(chain, block_height):
+ """Creates a new syncer session and commit its initial state to backend.
+
+ :param chain: Chain spec of chain that syncer is running for.
+ :type chain: cic_registry.chain.ChainSpec
+ :param block_height: Target block height
+ :type block_height: number
+ :returns: New syncer object
+ :rtype: cic_eth.db.models.BlockchainSync
+ """
+ object_id = None
+ session = SessionBase.create_session()
+ o = BlockchainSync(chain, 0, 0, block_height)
+ session.add(o)
+ session.commit()
+ object_id = o.id
+ session.close()
+
+ return SyncerBackend(chain, object_id)
+
+
+ @staticmethod
+ def resume(chain, block_height):
+ """Retrieves and returns all previously unfinished syncer sessions.
+
+
+ :param chain: Chain spec of chain that syncer is running for.
+ :type chain: cic_registry.chain.ChainSpec
+ :param block_height: Target block height
+ :type block_height: number
+ :returns: Syncer objects of unfinished syncs
+ :rtype: list of cic_eth.db.models.BlockchainSync
+ """
+ syncers = []
+
+ session = SessionBase.create_session()
+
+ object_id = None
+
+ for object_id in BlockchainSync.get_unsynced(session=session):
+ logg.debug('block syncer resume added previously unsynced sync entry id {}'.format(object_id))
+ syncers.append(SyncerBackend(chain, object_id))
+
+ (block_resume, tx_resume) = BlockchainSync.get_last_live_height(block_height, session=session)
+ if block_height != block_resume:
+ o = BlockchainSync(chain, block_resume, tx_resume, block_height)
+ session.add(o)
+ session.commit()
+ object_id = o.id
+ syncers.append(SyncerBackend(chain, object_id))
+ logg.debug('block syncer resume added new sync entry from previous run id {}, start{}:{} target {}'.format(object_id, block_resume, tx_resume, block_height))
+
+ session.close()
+
+ return syncers
+
+
+ @staticmethod
+ def live(chain, block_height):
+ """Creates a new open-ended syncer session starting at the given block height.
+
+ :param chain: Chain spec of chain that syncer is running for.
+ :type chain: cic_registry.chain.ChainSpec
+ :param block_height: Target block height
+ :type block_height: number
+ :returns: "Live" syncer object
+ :rtype: cic_eth.db.models.BlockchainSync
+ """
+ object_id = None
+ session = SessionBase.create_session()
+ o = BlockchainSync(chain, block_height, 0, None)
+ session.add(o)
+ session.commit()
+ object_id = o.id
+ session.close()
+
+ return SyncerBackend(chain, object_id)
diff --git a/apps/cic-eth/cic_eth/sync/base.py b/apps/cic-eth/cic_eth/sync/base.py
new file mode 100644
index 00000000..b678ccb7
--- /dev/null
+++ b/apps/cic-eth/cic_eth/sync/base.py
@@ -0,0 +1,51 @@
+# TODO: extend blocksync model
+class Syncer:
+ """Base class and interface for implementing a block sync poller routine.
+
+ :param bc_cache: Retrieves block cache cursors for chain head and latest processed block.
+ :type bc_cache: cic_eth.sync.SyncerBackend
+ """
+ w3 = None
+ running_global = True
+
+ def __init__(self, bc_cache):
+ self.cursor = None
+ self.bc_cache = bc_cache
+ self.filter = []
+ self.running = True
+
+
+ def chain(self):
+ """Returns the string representation of the chain spec for the chain the syncer is running on.
+
+ :returns: Chain spec string
+ :rtype: str
+ """
+ return self.bc_cache.chain()
+
+
+ def get(self):
+ """Get latest unprocessed blocks.
+
+ :returns: list of block hash strings
+ :rtype: list
+ """
+ raise NotImplementedError()
+
+
+ def process(self, w3, ref):
+ """Process transactions in a single block.
+
+ :param ref: Reference of object to process
+ :type ref: str, 0x-hex
+ """
+ raise NotImplementedError()
+
+
+ def loop(self, interval):
+ """Entry point for syncer loop
+
+ :param interval: Delay in seconds until next attempt if no new blocks are found.
+ :type interval: int
+ """
+ raise NotImplementedError()
diff --git a/apps/cic-eth/cic_eth/sync/error.py b/apps/cic-eth/cic_eth/sync/error.py
new file mode 100644
index 00000000..1d2ff27b
--- /dev/null
+++ b/apps/cic-eth/cic_eth/sync/error.py
@@ -0,0 +1,4 @@
+class LoopDone(Exception):
+ """Exception raised when a syncing is complete.
+ """
+ pass
diff --git a/apps/cic-eth/cic_eth/sync/head.py b/apps/cic-eth/cic_eth/sync/head.py
new file mode 100644
index 00000000..f96a75b7
--- /dev/null
+++ b/apps/cic-eth/cic_eth/sync/head.py
@@ -0,0 +1,51 @@
+# standard imports
+import logging
+
+# third-party imports
+import web3
+
+# local imports
+from .mined import MinedSyncer
+from .base import Syncer
+
+logg = logging.getLogger()
+
+
+class HeadSyncer(MinedSyncer):
+ """Implements the get method in Syncer for retrieving every new mined block.
+
+ :param bc_cache: Retrieves block cache cursors for chain head and latest processed block.
+ :type bc_cache: Object implementing methods from cic_eth.sync.SyncerBackend
+ """
+ def __init__(self, bc_cache):
+ super(HeadSyncer, self).__init__(bc_cache)
+ # TODO: filter not returning all blocks, at least with ganache. kind of defeats the point, then
+ #self.w3_filter = rpc.w3.eth.filter({
+ # 'fromBlock': block_offset,
+ # }) #'latest')
+ #self.bc_cache.set(block_offset, 0)
+ logg.debug('initialized head syncer with offset {}'.format(bc_cache.start()))
+
+ """Implements Syncer.get
+
+ :param w3: Web3 object
+ :type w3: web3.Web3
+ :returns: Block hash of newly mined blocks. if any
+ :rtype: list of str, 0x-hex
+ """
+ def get(self, w3):
+ # Of course, the filter doesn't return the same block dict format as getBlock() so we'll just waste some cycles getting the hashes instead.
+ #hashes = []
+ #for block in self.w3_filter.get_new_entries():
+ # hashes.append(block['blockHash'])
+ #logg.debug('blocks {}'.format(hashes))
+ #return hashes
+ (block_number, tx_number) = self.bc_cache.get()
+ block_hash = []
+ try:
+ block = w3.eth.getBlock(block_number)
+ block_hash.append(block.hash)
+ except web3.exceptions.BlockNotFound:
+ pass
+
+ return block_hash
diff --git a/apps/cic-eth/cic_eth/sync/history.py b/apps/cic-eth/cic_eth/sync/history.py
new file mode 100644
index 00000000..c75602b5
--- /dev/null
+++ b/apps/cic-eth/cic_eth/sync/history.py
@@ -0,0 +1,74 @@
+# standard imports
+import logging
+
+# third-party imports
+from web3.exceptions import BlockNotFound
+from .error import LoopDone
+
+# local imports
+from .mined import MinedSyncer
+from .base import Syncer
+from cic_eth.db.models.base import SessionBase
+
+logg = logging.getLogger()
+
+
+class HistorySyncer(MinedSyncer):
+ """Implements the get method in Syncer for retrieving all blocks between last processed block before previous shutdown and block height at time of syncer start.
+
+ :param bc_cache: Retrieves block cache cursors for chain head and latest processed block.
+ :type bc_cache: Object implementing methods from cic_eth.sync.SyncerBackend
+ :param mx: Maximum number of blocks to return in one call
+ :type mx: int
+ """
+ def __init__(self, bc_cache, mx=20):
+ super(HistorySyncer, self).__init__(bc_cache)
+ self.max = mx
+
+ self.target = bc_cache.target()
+ logg.info('History syncer target block number {}'.format(self.target))
+
+ session_offset = self.bc_cache.get()
+
+ self.block_offset = session_offset[0]
+ self.tx_offset = session_offset[1]
+ logg.info('History syncer starting at {}:{}'.format(session_offset[0], session_offset[1]))
+
+ self.filter = []
+
+
+ """Implements Syncer.get
+
+ BUG: Should also raise LoopDone when block array is empty after loop.
+
+ :param w3: Web3 object
+ :type w3: web3.Web3
+ :raises LoopDone: If a block is not found.
+ :return: Return a batch of blocks to process
+ :rtype: list of str, 0x-hex
+ """
+ def get(self, w3):
+ sync_db = self.bc_cache
+ height = self.bc_cache.get()
+ logg.debug('height {}'.format(height))
+ block_last = height[0]
+ tx_last = height[1]
+ if not self.running:
+ raise LoopDone((block_last, tx_last))
+ b = []
+ block_target = block_last + self.max
+ if block_target > self.target:
+ block_target = self.target
+ logg.debug('target {} last {} max {}'.format(block_target, block_last, self.max))
+ for i in range(block_last, block_target):
+ if i == self.target:
+ logg.info('reached target {}, exiting'.format(i))
+ self.running = False
+ break
+ bhash = w3.eth.getBlock(i).hash
+ b.append(bhash)
+ logg.debug('appending block {} {}'.format(i, bhash.hex()))
+ if block_last == block_target:
+ logg.info('aleady reached target {}, exiting'.format(self.target))
+ self.running = False
+ return b
diff --git a/apps/cic-eth/cic_eth/sync/mempool.py b/apps/cic-eth/cic_eth/sync/mempool.py
new file mode 100644
index 00000000..a3a62c6d
--- /dev/null
+++ b/apps/cic-eth/cic_eth/sync/mempool.py
@@ -0,0 +1,50 @@
+class MemPoolSyncer(Syncer):
+
+
+ def __init__(self, bc_cache):
+ raise NotImplementedError('incomplete, needs web3 tx to raw transaction conversion')
+ super(MemPoolSyncer, self).__init__(bc_cache)
+# self.w3_filter = Syncer.w3.eth.filter('pending')
+# for tx in tx_cache.txs:
+# self.txs.append(tx)
+# logg.debug('add tx {} to mempoolsyncer'.format(tx))
+#
+#
+# def get(self):
+# return self.w3_filter.get_new_entries()
+#
+#
+# def process(self, tx_hash):
+# tx_hash_hex = tx_hash.hex()
+# if tx_hash_hex in self.txs:
+# logg.debug('syncer already watching {}, skipping'.format(tx_hash_hex))
+# tx = self.w3.eth.getTransaction(tx_hash_hex)
+# serialized_tx = rlp.encode({
+# 'nonce': tx.nonce,
+# 'from': getattr(tx, 'from'),
+# })
+# logg.info('add {} to syncer: {}'.format(tx, serialized_tx))
+# otx = Otx(
+# nonce=tx.nonce,
+# address=getattr(tx, 'from'),
+# tx_hash=tx_hash_hex,
+# signed_tx=serialized_tx,
+# )
+# Otx.session.add(otx)
+# Otx.session.commit()
+#
+#
+# def loop(self, interval):
+# while Syncer.running:
+# logg.debug('loop execute')
+# txs = self.get()
+# logg.debug('got txs {}'.format(txs))
+# for tx in txs:
+# #block_number = self.process(block.hex())
+# self.process(tx)
+# #if block_number > self.bc_cache.head():
+# # self.bc_cache.head(block_number)
+# time.sleep(interval)
+# logg.info("Syncer no longer set to run, gracefully exiting")
+
+
diff --git a/apps/cic-eth/cic_eth/sync/mined.py b/apps/cic-eth/cic_eth/sync/mined.py
new file mode 100644
index 00000000..616eea54
--- /dev/null
+++ b/apps/cic-eth/cic_eth/sync/mined.py
@@ -0,0 +1,103 @@
+# standard imports
+import logging
+import time
+
+# third-party imports
+import celery
+
+# local impotes
+from .base import Syncer
+from cic_eth.queue.tx import set_final_status
+from cic_eth.eth import RpcClient
+
+app = celery.current_app
+logg = logging.getLogger()
+
+
+class MinedSyncer(Syncer):
+ """Base implementation of block processor for mined blocks.
+
+ Loops through all transactions,
+
+ :param bc_cache: Retrieves block cache cursors for chain head and latest processed block.
+ :type bc_cache: Object implementing methods from cic_eth.sync.SyncerBackend
+ """
+
+ def __init__(self, bc_cache):
+ super(MinedSyncer, self).__init__(bc_cache)
+ self.block_offset = 0
+ self.tx_offset = 0
+
+
+ def process(self, w3, ref):
+ """Processes transactions in a single block, advancing transaction (and block) cursor accordingly.
+
+ :param w3: Web3 object
+ :type w3: web3.Web3
+ :param ref: Block reference (hash) to process
+ :type ref: str, 0x-hex
+ :returns: Block number of next unprocessed block
+ :rtype: number
+ """
+ b = w3.eth.getBlock(ref)
+ c = w3.eth.getBlockTransactionCount(ref)
+ s = 0
+ if self.block_offset == b.number:
+ s = self.tx_offset
+
+ logg.debug('processing {} (blocknumber {}, count {}, offset {})'.format(ref, b.number, c, s))
+
+ for i in range(s, c):
+ tx = w3.eth.getTransactionByBlock(ref, i)
+ tx_hash_hex = tx['hash'].hex()
+ rcpt = w3.eth.getTransactionReceipt(tx_hash_hex)
+ logg.debug('{}/{} processing tx {} from block {} {}'.format(i+1, c, tx_hash_hex, b.number, ref))
+ ours = False
+ # TODO: ensure filter loop can complete on graceful shutdown
+ for f in self.filter:
+ #try:
+ task_uuid = f(w3, tx, rcpt, self.chain())
+ #except Exception as e:
+ # logg.error('error in filter {} tx {}: {}'.format(f, tx_hash_hex, e))
+ # continue
+ if task_uuid != None:
+ logg.debug('tx {} passed to celery task {}'.format(tx_hash_hex, task_uuid))
+ s = celery.signature(
+ 'set_final_status',
+ [tx_hash_hex, rcpt['blockNumber'], not rcpt['status']],
+ )
+ s.apply_async()
+ break
+ next_tx = i + 1
+ if next_tx == c:
+ self.bc_cache.set(b.number+1, 0)
+ else:
+ self.bc_cache.set(b.number, next_tx)
+ if c == 0:
+ logg.info('synced block {} has no transactions'.format(b.number))
+ #self.bc_cache.session(b.number+1, 0)
+ self.bc_cache.set(b.number+1, 0)
+ return b['number']
+
+
+
+ def loop(self, interval):
+ """Loop running until the "running" property of Syncer is set to False.
+
+ Retrieves latest unprocessed blocks and processes them.
+
+ :param interval: Delay in seconds until next attempt if no new blocks are found.
+ :type interval: int
+ """
+ while self.running and Syncer.running_global:
+ self.bc_cache.connect()
+ c = RpcClient(self.chain())
+ logg.debug('loop execute')
+ e = self.get(c.w3)
+ logg.debug('got blocks {}'.format(e))
+ for block in e:
+ block_number = self.process(c.w3, block.hex())
+ logg.info('processed block {} {}'.format(block_number, block.hex()))
+ self.bc_cache.disconnect()
+ time.sleep(interval)
+ logg.info("Syncer no longer set to run, gracefully exiting")
diff --git a/apps/cic-eth/cic_eth/sync/retry.py b/apps/cic-eth/cic_eth/sync/retry.py
new file mode 100644
index 00000000..302e4c75
--- /dev/null
+++ b/apps/cic-eth/cic_eth/sync/retry.py
@@ -0,0 +1,71 @@
+# standard imports
+import logging
+import datetime
+import time
+
+# third-party imports
+import celery
+
+# local imports
+from .base import Syncer
+from cic_eth.eth.rpc import RpcClient
+from cic_eth.db.enum import StatusEnum
+from cic_eth.queue.tx import get_status_tx
+
+logg = logging.getLogger()
+
+celery_app = celery.current_app
+
+
+class noop_cache:
+
+ def __init__(self, chain_spec):
+ self.chain_spec = chain_spec
+
+
+ def chain(self):
+ return self.chain_spec
+
+
+class RetrySyncer(Syncer):
+
+ def __init__(self, chain_spec, stalled_grace_seconds, failed_grace_seconds=None, final_func=None):
+ cache = noop_cache(chain_spec)
+ super(RetrySyncer, self).__init__(cache)
+ if failed_grace_seconds == None:
+ failed_grace_seconds = stalled_grace_seconds
+ self.stalled_grace_seconds = stalled_grace_seconds
+ self.failed_grace_seconds = failed_grace_seconds
+ self.final_func = final_func
+
+
+ def get(self, w3):
+# before = datetime.datetime.utcnow() - datetime.timedelta(seconds=self.failed_grace_seconds)
+# failed_txs = get_status_tx(
+# StatusEnum.SENDFAIL.value,
+# before=before,
+# )
+ before = datetime.datetime.utcnow() - datetime.timedelta(seconds=self.stalled_grace_seconds)
+ stalled_txs = get_status_tx(
+ StatusEnum.SENT.value,
+ before=before,
+ )
+ # return list(failed_txs.keys()) + list(stalled_txs.keys())
+ return stalled_txs
+
+
+ def process(self, w3, ref):
+ logg.debug('tx {}'.format(ref))
+ for f in self.filter:
+ f(w3, ref, None, str(self.chain()))
+
+
+ def loop(self, interval):
+ chain_str = str(self.chain())
+ while self.running and Syncer.running_global:
+ c = RpcClient(self.chain())
+ for tx in self.get(c.w3):
+ self.process(c.w3, tx)
+ if self.final_func != None:
+ self.final_func(chain_str)
+ time.sleep(interval)
diff --git a/apps/cic-eth/cic_eth/version.py b/apps/cic-eth/cic_eth/version.py
new file mode 100644
index 00000000..6a95f248
--- /dev/null
+++ b/apps/cic-eth/cic_eth/version.py
@@ -0,0 +1,43 @@
+# standard imports
+import os
+import time
+import logging
+
+# third-party imports
+import semver
+
+version = (
+ 0,
+ 10,
+ 0,
+ 'alpha.22',
+ )
+
+version_object = semver.VersionInfo(
+ major=version[0],
+ minor=version[1],
+ patch=version[2],
+ prerelease=version[3],
+ )
+
+
+def git_hash():
+ import subprocess
+ git_diff = subprocess.run(['git', 'diff'], capture_output=True)
+ git_hash = subprocess.run(['git', 'rev-parse', 'HEAD'], capture_output=True)
+ git_hash_brief = git_hash.stdout.decode('utf-8')[:8]
+ return git_hash_brief
+
+version_string = str(version_object)
+
+try:
+ version_git = git_hash()
+ version_string += '+build.{}'.format(version_git)
+except FileNotFoundError:
+ time_string_pair = str(time.time()).split('.')
+ version_string += '+build.{}{:<09d}'.format(
+ time_string_pair[0],
+ int(time_string_pair[1]),
+ )
+
+__version_string__ = version_string
diff --git a/apps/cic-eth/config/bancor.ini b/apps/cic-eth/config/bancor.ini
new file mode 100644
index 00000000..443924f5
--- /dev/null
+++ b/apps/cic-eth/config/bancor.ini
@@ -0,0 +1,2 @@
+[bancor]
+dir = /usr/local/share/cic/bancor
diff --git a/apps/cic-eth/config/celery.ini b/apps/cic-eth/config/celery.ini
new file mode 100644
index 00000000..af9fe5b1
--- /dev/null
+++ b/apps/cic-eth/config/celery.ini
@@ -0,0 +1,3 @@
+[celery]
+broker_url = redis://
+result_url = redis://
diff --git a/apps/cic-eth/config/cic.ini b/apps/cic-eth/config/cic.ini
new file mode 100644
index 00000000..2ad870e2
--- /dev/null
+++ b/apps/cic-eth/config/cic.ini
@@ -0,0 +1,8 @@
+[cic]
+registry_address =
+token_index_address =
+accounts_index_address =
+declarator_address =
+approval_escrow_address =
+chain_spec =
+tx_retry_delay =
diff --git a/apps/cic-eth/config/custody.ini b/apps/cic-eth/config/custody.ini
new file mode 100644
index 00000000..8523f03e
--- /dev/null
+++ b/apps/cic-eth/config/custody.ini
@@ -0,0 +1,2 @@
+[custody]
+account_index_address =
diff --git a/apps/cic-eth/config/database.ini b/apps/cic-eth/config/database.ini
new file mode 100644
index 00000000..43de56bf
--- /dev/null
+++ b/apps/cic-eth/config/database.ini
@@ -0,0 +1,9 @@
+[database]
+NAME=cic-eth
+USER=postgres
+PASSWORD=
+HOST=localhost
+PORT=5432
+ENGINE=postgresql
+DRIVER=psycopg2
+DEBUG=
diff --git a/apps/cic-eth/config/dispatcer.ini b/apps/cic-eth/config/dispatcer.ini
new file mode 100644
index 00000000..85dea83e
--- /dev/null
+++ b/apps/cic-eth/config/dispatcer.ini
@@ -0,0 +1,2 @@
+[dispatcher]
+loop_interval = 0.9
diff --git a/apps/cic-eth/config/eth.ini b/apps/cic-eth/config/eth.ini
new file mode 100644
index 00000000..1a6935e1
--- /dev/null
+++ b/apps/cic-eth/config/eth.ini
@@ -0,0 +1,8 @@
+[eth]
+#ws_provider = ws://localhost:8546
+#ttp_provider = http://localhost:8545
+provider = http://localhost:8545
+gas_provider_address =
+#chain_id =
+abi_dir = /usr/local/share/cic/solidity/abi
+account_accounts_index_writer =
diff --git a/apps/cic-eth/config/lash/bancor.ini b/apps/cic-eth/config/lash/bancor.ini
new file mode 100644
index 00000000..0bff1ce0
--- /dev/null
+++ b/apps/cic-eth/config/lash/bancor.ini
@@ -0,0 +1,3 @@
+[bancor]
+registry_address = 0xb708175e3f6Cd850643aAF7B32212AFad50e2549
+dir = /home/lash/src/ext/cic/grassrootseconomics/cic-platform/contrib/bancor_0.6
diff --git a/apps/cic-eth/config/lash/database.ini b/apps/cic-eth/config/lash/database.ini
new file mode 100644
index 00000000..77ac57d4
--- /dev/null
+++ b/apps/cic-eth/config/lash/database.ini
@@ -0,0 +1,8 @@
+[database]
+NAME=cic-eth
+USER=postgres
+PASSWORD=
+HOST=localhost
+PORT=5432
+ENGINE=sqlite
+DRIVER=pysqlite
diff --git a/apps/cic-eth/config/lash/eth.ini b/apps/cic-eth/config/lash/eth.ini
new file mode 100644
index 00000000..324dba08
--- /dev/null
+++ b/apps/cic-eth/config/lash/eth.ini
@@ -0,0 +1,3 @@
+[eth]
+gas_provider_address = 0xEb3907eCad74a0013c259D5874AE7f22DcBcC95C
+provider = http://localhost:8545
diff --git a/apps/cic-eth/config/lash/redis.ini b/apps/cic-eth/config/lash/redis.ini
new file mode 100644
index 00000000..d21df9f8
--- /dev/null
+++ b/apps/cic-eth/config/lash/redis.ini
@@ -0,0 +1,3 @@
+[celery]
+broker_url = redis://
+result_url = file://
diff --git a/apps/cic-eth/config/lash/signer.ini b/apps/cic-eth/config/lash/signer.ini
new file mode 100644
index 00000000..9222aef8
--- /dev/null
+++ b/apps/cic-eth/config/lash/signer.ini
@@ -0,0 +1,2 @@
+[signer]
+socket_path = /tmp/crypto-dev-signer/jsonrpc.ipc
diff --git a/apps/cic-eth/config/lash/ssl.ini b/apps/cic-eth/config/lash/ssl.ini
new file mode 100644
index 00000000..746ff856
--- /dev/null
+++ b/apps/cic-eth/config/lash/ssl.ini
@@ -0,0 +1,6 @@
+[SSL]
+enable_client = true
+cert_file = /home/lash/src/ext/cic/grassrootseconomics/cic-auth/examples/client.crt
+key_file = /home/lash/src/ext/cic/grassrootseconomics/cic-auth/examples/client.key
+password = test
+ca_file = /home/lash/src/ext/cic/grassrootseconomics/cic-auth/examples/ca.crt
diff --git a/apps/cic-eth/config/lash/syncer.ini b/apps/cic-eth/config/lash/syncer.ini
new file mode 100644
index 00000000..97236743
--- /dev/null
+++ b/apps/cic-eth/config/lash/syncer.ini
@@ -0,0 +1,2 @@
+[SYNCER]
+loop_interval = 1
diff --git a/apps/cic-eth/config/redis.ini b/apps/cic-eth/config/redis.ini
new file mode 100644
index 00000000..1a7acb52
--- /dev/null
+++ b/apps/cic-eth/config/redis.ini
@@ -0,0 +1,4 @@
+[redis]
+host =
+port =
+db =
diff --git a/apps/cic-eth/config/signer.ini b/apps/cic-eth/config/signer.ini
new file mode 100644
index 00000000..0fa1f015
--- /dev/null
+++ b/apps/cic-eth/config/signer.ini
@@ -0,0 +1,5 @@
+[signer]
+socket_path = /run/crypto-dev-signer/jsonrpc.ipc
+secret = deedbeef
+database_name = signer_test
+dev_keys_path =
diff --git a/apps/cic-eth/config/ssl.ini b/apps/cic-eth/config/ssl.ini
new file mode 100644
index 00000000..bd494729
--- /dev/null
+++ b/apps/cic-eth/config/ssl.ini
@@ -0,0 +1,6 @@
+[SSL]
+enable_client = false
+cert_file =
+key_file =
+password =
+ca_file =
diff --git a/apps/cic-eth/config/syncer.ini b/apps/cic-eth/config/syncer.ini
new file mode 100644
index 00000000..97236743
--- /dev/null
+++ b/apps/cic-eth/config/syncer.ini
@@ -0,0 +1,2 @@
+[SYNCER]
+loop_interval = 1
diff --git a/apps/cic-eth/config/tasks.ini b/apps/cic-eth/config/tasks.ini
new file mode 100644
index 00000000..5519eaac
--- /dev/null
+++ b/apps/cic-eth/config/tasks.ini
@@ -0,0 +1,3 @@
+[tasks]
+transfer_callbacks = taskcall:cic_eth.callbacks.noop.noop
+trace_queue_status =
diff --git a/apps/cic-eth/config/test/accounts.ini b/apps/cic-eth/config/test/accounts.ini
new file mode 100644
index 00000000..819a83bc
--- /dev/null
+++ b/apps/cic-eth/config/test/accounts.ini
@@ -0,0 +1,2 @@
+[accounts]
+writer_address =
diff --git a/apps/cic-eth/config/test/bancor.ini b/apps/cic-eth/config/test/bancor.ini
new file mode 100644
index 00000000..961c0e6b
--- /dev/null
+++ b/apps/cic-eth/config/test/bancor.ini
@@ -0,0 +1,2 @@
+[bancor]
+dir = tests/testdata/bancor
diff --git a/apps/cic-eth/config/test/celery.ini b/apps/cic-eth/config/test/celery.ini
new file mode 100644
index 00000000..1f12b77f
--- /dev/null
+++ b/apps/cic-eth/config/test/celery.ini
@@ -0,0 +1,5 @@
+[celery]
+broker_url = filesystem://
+result_url = filesystem://
+#broker_url = redis://
+#result_url = redis://
diff --git a/apps/cic-eth/config/test/cic.ini b/apps/cic-eth/config/test/cic.ini
new file mode 100644
index 00000000..efd8fc4b
--- /dev/null
+++ b/apps/cic-eth/config/test/cic.ini
@@ -0,0 +1,8 @@
+[cic]
+registry_address =
+token_index_address =
+accounts_index_address =
+declarator_address =
+approval_escrow_address =
+chain_spec =
+trusted_addresses =
diff --git a/apps/cic-eth/config/test/database.ini b/apps/cic-eth/config/test/database.ini
new file mode 100644
index 00000000..8c355ef3
--- /dev/null
+++ b/apps/cic-eth/config/test/database.ini
@@ -0,0 +1,9 @@
+[database]
+NAME=cic-eth-test
+USER=postgres
+PASSWORD=
+HOST=localhost
+PORT=5432
+ENGINE=sqlite
+DRIVER=pysqlite
+DEBUG=
diff --git a/apps/cic-eth/config/test/dispatcher.ini b/apps/cic-eth/config/test/dispatcher.ini
new file mode 100644
index 00000000..f7b270a5
--- /dev/null
+++ b/apps/cic-eth/config/test/dispatcher.ini
@@ -0,0 +1,2 @@
+[dispatcher]
+loop_interval = 0.1
diff --git a/apps/cic-eth/config/test/eth.ini b/apps/cic-eth/config/test/eth.ini
new file mode 100644
index 00000000..4c9edda1
--- /dev/null
+++ b/apps/cic-eth/config/test/eth.ini
@@ -0,0 +1,8 @@
+[eth]
+#ws_provider = ws://localhost:8546
+#ttp_provider = http://localhost:8545
+provider = http://localhost:8545
+gas_provider_address =
+#chain_id =
+abi_dir =
+faucet_giver_address =
diff --git a/apps/cic-eth/config/test/redis.ini b/apps/cic-eth/config/test/redis.ini
new file mode 100644
index 00000000..2fb1d805
--- /dev/null
+++ b/apps/cic-eth/config/test/redis.ini
@@ -0,0 +1,4 @@
+[redis]
+host =
+port =
+db =
diff --git a/apps/cic-eth/config/test/signer.ini b/apps/cic-eth/config/test/signer.ini
new file mode 100644
index 00000000..0fa1f015
--- /dev/null
+++ b/apps/cic-eth/config/test/signer.ini
@@ -0,0 +1,5 @@
+[signer]
+socket_path = /run/crypto-dev-signer/jsonrpc.ipc
+secret = deedbeef
+database_name = signer_test
+dev_keys_path =
diff --git a/apps/cic-eth/config/test/ssl.ini b/apps/cic-eth/config/test/ssl.ini
new file mode 100644
index 00000000..bd494729
--- /dev/null
+++ b/apps/cic-eth/config/test/ssl.ini
@@ -0,0 +1,6 @@
+[SSL]
+enable_client = false
+cert_file =
+key_file =
+password =
+ca_file =
diff --git a/apps/cic-eth/config/test/syncer.ini b/apps/cic-eth/config/test/syncer.ini
new file mode 100644
index 00000000..97236743
--- /dev/null
+++ b/apps/cic-eth/config/test/syncer.ini
@@ -0,0 +1,2 @@
+[SYNCER]
+loop_interval = 1
diff --git a/apps/cic-eth/crypto_dev_signer_config/config.ini b/apps/cic-eth/crypto_dev_signer_config/config.ini
new file mode 100644
index 00000000..f87759df
--- /dev/null
+++ b/apps/cic-eth/crypto_dev_signer_config/config.ini
@@ -0,0 +1,4 @@
+[signer]
+secret = deadbeef
+#database = crypto-dev-signer
+socket_path = /run/crypto-dev-signer/jsonrpc.ipc
diff --git a/apps/cic-eth/crypto_dev_signer_config/database.ini b/apps/cic-eth/crypto_dev_signer_config/database.ini
new file mode 100644
index 00000000..5eec2537
--- /dev/null
+++ b/apps/cic-eth/crypto_dev_signer_config/database.ini
@@ -0,0 +1,8 @@
+[database]
+NAME=cic-signer
+USER=
+PASSWORD=
+HOST=
+PORT=
+ENGINE=
+DRIVER=
diff --git a/apps/cic-eth/doc/flowcharts/Makefile b/apps/cic-eth/doc/flowcharts/Makefile
new file mode 100644
index 00000000..a5969abb
--- /dev/null
+++ b/apps/cic-eth/doc/flowcharts/Makefile
@@ -0,0 +1,15 @@
+INPUTS = $(wildcard *.dot)
+OUTPUTS = $(patsubst %.dot, %.png, $(INPUTS))
+
+.SUFFIXES: .dot .png
+
+.dot.png:
+ dot -T png $(basename $@).dot > $@
+
+all: $(OUTPUTS)
+
+clean:
+ rm -vf *.png
+
+.PHONY: clean
+
diff --git a/apps/cic-eth/doc/flowcharts/account_tasks.dot b/apps/cic-eth/doc/flowcharts/account_tasks.dot
new file mode 100644
index 00000000..29a628a8
--- /dev/null
+++ b/apps/cic-eth/doc/flowcharts/account_tasks.dot
@@ -0,0 +1,21 @@
+digraph {
+
+ create_account [
+ label="CIC-ETH API:\create account";
+ shape="ellipse";
+ ];
+
+ callback [
+ label="callback";
+ shape="ellipse";
+ style="dashed";
+ ];
+
+ create_account -> "eth.account.create";
+ create_account -> "eth.account.register" -> "eth.account.cache_account_data";
+ "eth.account.register" -> "queue.tx,create";
+ "eth.account.register" -> "eth.tx.check_gas";
+ "eth.tx.check_gas" -> "eth.tx.refill_gas" [ style="dashed" ];
+ "eth.tx.check_gas" -> callback [ style="dashed" ];
+ "eth.tx.refill_gas" -> callback [ style="dashed" ];
+}
diff --git a/apps/cic-eth/doc/flowcharts/balance_tasks.dot b/apps/cic-eth/doc/flowcharts/balance_tasks.dot
new file mode 100644
index 00000000..6a2d7fde
--- /dev/null
+++ b/apps/cic-eth/doc/flowcharts/balance_tasks.dot
@@ -0,0 +1,16 @@
+digraph {
+ balance [
+ label="CIC-ETH API:\nbalance";
+ shape="ellipse";
+ ];
+
+ callback [
+ label="callback";
+ shape="ellipse";
+ style="dashed";
+ ];
+
+ balance -> "eth.token.resolve_tokens_by_symbol"
+ "eth.token.resolve_tokens_by_symbol" -> "eth.token.balance"
+ "eth.token.balance" -> callback [ style="dashed" ];
+}
diff --git a/apps/cic-eth/doc/flowcharts/callback_gift.dot b/apps/cic-eth/doc/flowcharts/callback_gift.dot
new file mode 100644
index 00000000..576fe4e6
--- /dev/null
+++ b/apps/cic-eth/doc/flowcharts/callback_gift.dot
@@ -0,0 +1,10 @@
+digraph {
+
+ tx [
+ label="CIC-MANAGER\ncallbacks filter, tokengift";
+ shape="ellipse";
+ ];
+
+ tx -> callback [ style="dashed" ];
+
+}
diff --git a/apps/cic-eth/doc/flowcharts/convert_tasks.dot b/apps/cic-eth/doc/flowcharts/convert_tasks.dot
new file mode 100644
index 00000000..79bef521
--- /dev/null
+++ b/apps/cic-eth/doc/flowcharts/convert_tasks.dot
@@ -0,0 +1,57 @@
+digraph {
+
+ convert_transfer [
+ label="CIC-ETH API:\nconvert_transfer";
+ shape="ellipse";
+ ];
+
+ callback [
+ label="callback";
+ shape="ellipse";
+ style="dashed";
+ ];
+
+ convert_approve_zero [
+ label="eth.token.approve (zero)";
+ shape="ellipse";
+ ];
+
+ convert_approve_amount [
+ label="eth.token.approve (amount)";
+ shape="ellipse";
+ ];
+
+ cache_approve_zero [
+ label="eth.token.otx_cache_approve";
+ shape="ellipse";
+ ];
+
+ cache_approve_amount [
+ label="eth.token.otx_cache_approve";
+ shape="ellipse";
+ ];
+
+ queue_approve_zero [
+ label="queue.tx.create";
+ shape="ellipse";
+ ];
+
+ queue_approve_amount [
+ label="queue.tx.create";
+ shape="ellipse";
+ ];
+
+ convert_transfer -> "eth.token.resolve_tokens_by_symbol" -> "eth.bancor.convert_with_default_reserve";
+ "eth.bancor.convert_with_default_reserve" -> convert_approve_zero -> cache_approve_zero;
+ convert_approve_zero -> queue_approve_zero;
+ "eth.bancor.convert_with_default_reserve" -> convert_approve_amount -> cache_approve_amount;
+ convert_approve_amount -> queue_approve_amount;
+ "eth.bancor.convert_with_default_reserve" -> "eth.bancor.otx_cache_convert";
+ "eth.bancor.convert_with_default_reserve" -> "queue.tx.create";
+ "eth.bancor.convert_with_default_reserve" -> "eth.tx.check_gas";
+ "eth.bancor.convert_with_default_reserve" -> "eth.bancor.save_convert_recipient";
+ "eth.tx.check_gas" -> "eth.tx.refill_gas" [ style="dashed" ];
+ "eth.tx.check_gas" -> callback [ style="dashed" ];
+ "eth.tx.refill_gas" -> callback [ style="dashed" ];
+
+}
diff --git a/apps/cic-eth/doc/flowcharts/converttransfer_tasks.dot b/apps/cic-eth/doc/flowcharts/converttransfer_tasks.dot
new file mode 100644
index 00000000..93da1a6b
--- /dev/null
+++ b/apps/cic-eth/doc/flowcharts/converttransfer_tasks.dot
@@ -0,0 +1,15 @@
+digraph {
+
+ tx [
+ label="CIC-MANAGER;\nconvert_filter";
+ shape="ellipse";
+ ];
+
+ tx -> "eth.bancor.transfer_converted" -> "eth.token.otx_cache_transfer";
+ "eth.bancor.transfer_converted" -> "queue.tx.create";
+ "eth.bancor.transfer_converted" -> "eth.bancor.save_convert_transfer";
+ "eth.bancor.transfer_converted" -> "eth.tx.check_gas";
+ "eth.tx.check_gas" -> "eth.tx.refill_gas" [ style="dashed" ];
+ "eth.tx.check_gas" -> callback [ style="dashed" ];
+ "eth.tx.refill_gas" -> callback [ style="dashed" ];
+}
diff --git a/apps/cic-eth/doc/flowcharts/dispatch.dot b/apps/cic-eth/doc/flowcharts/dispatch.dot
new file mode 100644
index 00000000..b715aedc
--- /dev/null
+++ b/apps/cic-eth/doc/flowcharts/dispatch.dot
@@ -0,0 +1,159 @@
+digraph G {
+
+ send [
+ label = "transfer";
+ shape = "ellipse";
+ ];
+
+ params [
+ label = "get token, value, sender, recipient";
+ shape = "parallelogram";
+ ];
+
+ token_lookup [
+ label = "token known?";
+ shape = "diamond";
+ ];
+
+ token_lookup_x [
+ xlabel = "UnknownTokenError";
+ shape = "point";
+ ];
+
+ nonce [
+ label = "get sender nonce";
+ shape = "box";
+ style = "dashed";
+ ];
+
+ sign_tx [
+ label = "sign tx";
+ shape = "box";
+ ];
+
+ sign_tx_x [
+ xlabel = "SignerError";
+ shape = "point";
+ ];
+
+ cache [
+ label = "queue signed tx";
+ shape = "cylinder";
+ ];
+
+ gas [
+ label = "safe sender balance for gas?";
+ shape = "diamond";
+ ];
+
+ gas_rq_exists [
+ label = "gas request already pending?"
+ shape = "diamond";
+ ];
+
+ gas_rq [
+ label = "queue request for gas";
+ shape = "parallelogram";
+ ];
+
+ gas_tx [
+ label = "enough gas for this tx?";
+ shape = "diamond";
+ ];
+
+ cache_waitforgas [
+ label = "set status to WAITFORGAS";
+ shape = "parallelogram";
+ ];
+
+ gas_tx_x [
+ xlabel = "OutOfGasError";
+ shape = "point";
+ ];
+
+ tx_fail [
+ label = "temporary error?"
+ shape = "diamond"
+ ];
+
+ tx_fail_known [
+ label = "known error?"
+ shape = "diamond"
+ ];
+
+ cache_sent [
+ label = "set tx status to SENT";
+ shape = "cylinder";
+ ];
+
+ cache_unsent [
+ label = "set tx status to SENDFAIL";
+ shape = "cylinder";
+ ];
+
+ cache_revert [
+ label = "set tx status to REVERTED";
+ shape = "cylinder";
+ ];
+
+ cache_fubar [
+ label = "set tx status to FUBAR";
+ shape = "cylinder";
+ ];
+
+ send_tx_x_tmp [
+ xlabel = "TemporaryTxError";
+ shape = "point";
+ ];
+
+ send_tx_x_final [
+ xlabel = "PermanentTxError";
+ shape = "point";
+ ];
+
+ ok [
+ shape = "point";
+ ];
+
+
+ send -> params -> token_lookup;
+
+ token_lookup -> token_lookup_x [ label = "no"; ];
+
+ token_lookup -> nonce [ label = "yes"; ];
+ nonce -> sign_tx;
+
+ sign_tx -> sign_tx_x [ label = "fail"; ];
+
+ sign_tx -> cache [ label = "ok"; ];
+ cache -> gas;
+
+ gas -> gas_rq_exists [ label = "no"; ];
+ gas_rq_exists -> gas_rq [ label = "no"; ];
+ gas_rq_exists -> gas_tx [ label = "yes"; ];
+ gas_rq -> gas_tx;
+
+ gas -> send_tx [ label = "yes"; ];
+
+ gas_tx -> cache_waitforgas -> gas_tx_x [ label = "no"; ];
+
+ gas_tx -> send_tx [ label = "yes"; ];
+
+ send_tx -> tx_fail [ label = "fail"; ];
+
+ tx_fail -> cache_unsent [ label = "yes"; ];
+ cache_unsent -> send_tx_x_tmp;
+
+ tx_fail -> tx_fail_known [ label = "no"; ];
+
+ tx_fail_known -> cache_fubar [ label = "no"; ];
+
+ cache_fubar -> send_tx_x_final;
+
+ tx_fail_known -> cache_revert [ label = "yes"; ];
+ cache_revert -> send_tx_x_final;
+
+ send_tx -> cache_sent [ label = "ok"; ];
+ cache_sent -> ok;
+
+}
diff --git a/apps/cic-eth/doc/flowcharts/readme b/apps/cic-eth/doc/flowcharts/readme
new file mode 100644
index 00000000..1246e436
--- /dev/null
+++ b/apps/cic-eth/doc/flowcharts/readme
@@ -0,0 +1,3 @@
+All *_tasks.dot files describe literal the literal tasks that get executed on the associated entry points. CIC-ETH API entrypoints refer to methods in "cic_eth/api/api_task.py"
+
+All *_semantic.dot files are flow charts decribing the processing of the associated entry points.
diff --git a/apps/cic-eth/doc/flowcharts/register_tasks.dot b/apps/cic-eth/doc/flowcharts/register_tasks.dot
new file mode 100644
index 00000000..2541b856
--- /dev/null
+++ b/apps/cic-eth/doc/flowcharts/register_tasks.dot
@@ -0,0 +1,12 @@
+digraph {
+
+ send [
+ label="CIC-MANAGER\nregistration filter";
+ shape="ellipse";
+ ];
+
+ send -> "eth.account.gift" -> "eth.account.cache_gift_data";
+ "eth.account.gift" -> "queue.tx.create";
+ "eth.account.gift" -> "eth.tx.check_gas";
+ "eth.tx.check_gas" -> "eth.tx.refill_gas" [ style="dashed" ];
+}
diff --git a/apps/cic-eth/doc/flowcharts/send_tasks.dot b/apps/cic-eth/doc/flowcharts/send_tasks.dot
new file mode 100644
index 00000000..847960cd
--- /dev/null
+++ b/apps/cic-eth/doc/flowcharts/send_tasks.dot
@@ -0,0 +1,17 @@
+digraph {
+
+ dispatcher [
+ label="CIC-ETH-DISPATCHER";
+ shape="ellipse";
+ ];
+
+ send [
+ label="eth.tx.send";
+ shape="ellipse";
+ ];
+
+ dispatcher -> send;
+ send -> "queue.tx.set_[sent|final|fubar]_status";
+ send -> "(send tx on blockchain)";
+ "queue.tx.set_[sent|final|fubar]_status" -> send [ style="dashed" ];
+}
diff --git a/apps/cic-eth/doc/flowcharts/transaction_semantic.dot b/apps/cic-eth/doc/flowcharts/transaction_semantic.dot
new file mode 100644
index 00000000..2374ac1d
--- /dev/null
+++ b/apps/cic-eth/doc/flowcharts/transaction_semantic.dot
@@ -0,0 +1,104 @@
+digraph G {
+
+ send [
+ label = "transfer";
+ shape = "ellipse";
+ ];
+
+ params [
+ label = "get token, value, sender, recipient";
+ shape = "parallelogram";
+ ];
+
+ token_lookup [
+ label = "token known?";
+ shape = "diamond";
+ ];
+
+ token_lookup_x [
+ xlabel = "UnknownTokenError";
+ shape = "point";
+ ];
+
+ nonce [
+ label = "get sender nonce";
+ shape = "box";
+ style = "dashed";
+ ];
+
+ sign_tx [
+ label = "sign tx";
+ shape = "box";
+ ];
+
+ sign_tx_x [
+ xlabel = "SignerError";
+ shape = "point";
+ ];
+
+ cache [
+ label = "queue signed tx";
+ shape = "cylinder";
+ ];
+
+ gas [
+ label = "safe sender balance for gas?";
+ shape = "diamond";
+ ];
+
+ gas_rq_exists [
+ label = "gas request already pending?"
+ shape = "diamond";
+ ];
+
+ gas_rq [
+ label = "queue request for gas";
+ shape = "parallelogram";
+ ];
+
+ gas_tx [
+ label = "enough gas for this tx?";
+ shape = "diamond";
+ ];
+
+ cache_waitforgas [
+ label = "set status to WAITFORGAS";
+ shape = "parallelogram";
+ ];
+
+ gas_tx_x [
+ xlabel = "OutOfGasError";
+ shape = "point";
+ ];
+
+ ok [
+ xlabel = "OK";
+ shape = "point";
+ ];
+
+
+ send -> params -> token_lookup;
+
+ token_lookup -> token_lookup_x [ label = "no"; ];
+
+ token_lookup -> nonce [ label = "yes"; ];
+ nonce -> sign_tx;
+
+ sign_tx -> sign_tx_x [ label = "fail"; ];
+
+ sign_tx -> cache [ label = "ok"; ];
+ cache -> gas;
+
+ gas -> gas_rq_exists [ label = "no"; ];
+ gas_rq_exists -> gas_rq [ label = "no"; ];
+ gas_rq_exists -> gas_tx [ label = "yes"; ];
+ gas_rq -> gas_tx;
+
+ gas -> ok [ label = "yes"; ];
+
+ gas_tx -> cache_waitforgas -> gas_tx_x [ label = "no"; ];
+
+ gas_tx -> ok [ label = "yes"; ];
+
+
+}
diff --git a/apps/cic-eth/doc/flowcharts/transaction_tasks.dot b/apps/cic-eth/doc/flowcharts/transaction_tasks.dot
new file mode 100644
index 00000000..41d82bd7
--- /dev/null
+++ b/apps/cic-eth/doc/flowcharts/transaction_tasks.dot
@@ -0,0 +1,22 @@
+digraph {
+
+ send [
+ label="CIC-ETH API:\ntransfer";
+ shape="ellipse";
+ ];
+
+ callback [
+ label="callback";
+ shape="ellipse";
+ style="dashed";
+ ];
+
+ send -> "eth.token.resolve_tokens_by_symbol"
+ "eth.token.resolve_tokens_by_symbol" -> "eth.token.transfer" -> "eth.queue.otx_cache_transfer";
+ "eth.token.transfer" -> "eth.queue.tx.create";
+ "eth.token.transfer" -> "eth.tx.check_gas";
+ "eth.tx.check_gas" -> "eth.tx.refill_gas" [ style="dashed" ];
+ "eth.tx.check_gas" -> callback [ style="dashed" ];
+ "eth.tx.refill_gas" -> callback [ style="dashed" ];
+
+}
diff --git a/apps/cic-eth/doc/flowcharts/transferauthorization_tasks.dot b/apps/cic-eth/doc/flowcharts/transferauthorization_tasks.dot
new file mode 100644
index 00000000..86ee737c
--- /dev/null
+++ b/apps/cic-eth/doc/flowcharts/transferauthorization_tasks.dot
@@ -0,0 +1,65 @@
+digraph {
+
+ transferauthorization [
+ label="CIC-ETH API:\ntransfer authorization";
+ shape="ellipse";
+ ];
+
+ callback [
+ label="callback";
+ shape="ellipse";
+ style="dashed";
+ ];
+
+ resolve_transferauthorization [
+ label="eth.token.resolve_tokens_by_symbol";
+ shape="ellipse";
+ ];
+
+ resolve_approve [
+ label="eth.token.resolve_tokens_by_symbol";
+ shape="ellipse";
+ ];
+
+ checkgas_transferauthorization [
+ label="eth.tx.check_gas";
+ shape="ellipse";
+ ];
+
+ checkgas_approve [
+ label="eth.tx.check_gas";
+ shape="ellipse";
+ ];
+
+ refill_transferauthorization [
+ label="eth.tx.refill_gas";
+ shape="ellipse";
+ ];
+
+ refill_approve [
+ label="eth.tx.refill_gas";
+ shape="ellipse";
+ ];
+
+ queue_create_transferauthorization [
+ label="queue.tx.create";
+ shape="ellipse";
+ ];
+
+ queue_create_approve [
+ label="queue.tx.create";
+ shape="ellipse";
+ ];
+
+ transferauthorization -> resolve_approve -> "eth.token.approve" -> "eth.token.otx_cache_approve";
+ "eth.token.approve" -> queue_create_approve;
+ "eth.token.approve" -> checkgas_approve;
+ checkgas_approve -> refill_approve [ style="dashed" ];
+
+ transferauthorization -> resolve_transferauthorization -> "eth.request.transfer_approve_request" -> "eth.token.otx_cache_transfer_approval_request";
+ "eth.request.transfer_approve_request" -> queue_create_transferauthorization;
+ "eth.request.transfer_approve_request" -> checkgas_transferauthorization;
+ checkgas_transferauthorization -> refill_transferauthorization [ style="dashed" ];
+ checkgas_approve -> callback [ style="dashed" ];
+ refill_approve -> callback [ style="dashed" ];
+}
diff --git a/apps/cic-eth/doc/flowcharts/tx_tasks.dot b/apps/cic-eth/doc/flowcharts/tx_tasks.dot
new file mode 100644
index 00000000..0f3927cb
--- /dev/null
+++ b/apps/cic-eth/doc/flowcharts/tx_tasks.dot
@@ -0,0 +1,9 @@
+digraph {
+
+ tx [
+ label="CIC-MANAGER;\ntx_filter";
+ shape="ellipse";
+ ];
+
+ tx -> "queue.tx.set_final_status";
+}
diff --git a/apps/cic-eth/doc/sphinx/Makefile b/apps/cic-eth/doc/sphinx/Makefile
new file mode 100644
index 00000000..f9d4fcb2
--- /dev/null
+++ b/apps/cic-eth/doc/sphinx/Makefile
@@ -0,0 +1,20 @@
+# Minimal makefile for Sphinx documentation
+#
+
+# You can set these variables from the command line, and also
+# from the environment for the first two.
+SPHINXOPTS ?=
+SPHINXBUILD ?= sphinx-build
+SOURCEDIR = .
+BUILDDIR = _build
+
+# Put it first so that "make" without argument is like "make help".
+help:
+ @PYTHONPATH=../.. $(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
+
+.PHONY: help Makefile
+
+# Catch-all target: route all unknown targets to Sphinx using the new
+# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
+%: Makefile
+ @PYTHONPATH=../.. $(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
diff --git a/apps/cic-eth/doc/sphinx/code.rst b/apps/cic-eth/doc/sphinx/code.rst
new file mode 100644
index 00000000..97fd314e
--- /dev/null
+++ b/apps/cic-eth/doc/sphinx/code.rst
@@ -0,0 +1,56 @@
+Package cic_eth
+===============
+
+.. automodule:: cic_eth
+
+
+Module eth
+==========
+
+.. automodule:: cic_eth.eth
+ :members:
+
+.. automodule:: cic_eth.eth.factory
+ :members:
+
+.. automodule:: cic_eth.eth.tx
+ :members:
+
+.. automodule:: cic_eth.eth.account
+ :members:
+
+.. automodule:: cic_eth.eth.bancor
+ :members:
+
+.. automodule:: cic_eth.eth.token
+ :members:
+
+.. automodule:: cic_eth.eth.tasks
+ :members:
+
+
+Module queue
+============
+
+.. automodule:: cic_eth.queue.tx
+ :members:
+
+
+Module sync
+===========
+
+.. automodule:: cic_eth.sync.base
+ :members:
+
+.. automodule:: cic_eth.sync.mined
+ :members:
+
+.. automodule:: cic_eth.sync.mined
+ :members:
+
+.. automodule:: cic_eth.sync.head
+ :members:
+
+.. automodule:: cic_eth.sync.history
+ :members:
+
diff --git a/apps/cic-eth/doc/sphinx/conf.py b/apps/cic-eth/doc/sphinx/conf.py
new file mode 100644
index 00000000..679d1d71
--- /dev/null
+++ b/apps/cic-eth/doc/sphinx/conf.py
@@ -0,0 +1,57 @@
+# Configuration file for the Sphinx documentation builder.
+#
+# This file only contains a selection of the most common options. For a full
+# list see the documentation:
+# https://www.sphinx-doc.org/en/master/usage/configuration.html
+
+# -- Path setup --------------------------------------------------------------
+
+# If extensions (or modules to document with autodoc) are in another directory,
+# add these directories to sys.path here. If the directory is relative to the
+# documentation root, use os.path.abspath to make it absolute, like shown here.
+#
+# import os
+# import sys
+# sys.path.insert(0, os.path.abspath('.'))
+
+
+# -- Project information -----------------------------------------------------
+
+project = 'cic-eth'
+copyright = '2020, Louis Holbrook'
+author = 'Louis Holbrook'
+
+
+# -- General configuration ---------------------------------------------------
+
+# Add any Sphinx extension module names here, as strings. They can be
+# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
+# ones.
+extensions = [
+ 'sphinx.ext.autodoc',
+ 'celery.contrib.sphinx',
+ 'sphinx.ext.todo',
+]
+
+# Add any paths that contain templates here, relative to this directory.
+templates_path = ['_templates']
+
+# List of patterns, relative to source directory, that match files and
+# directories to ignore when looking for source files.
+# This pattern also affects html_static_path and html_extra_path.
+exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store']
+
+
+# -- Options for HTML output -------------------------------------------------
+
+# The theme to use for HTML and HTML Help pages. See the documentation for
+# a list of builtin themes.
+#
+html_theme = 'alabaster'
+
+# Add any paths that contain custom static files (such as style sheets) here,
+# relative to this directory. They are copied after the builtin static files,
+# so a file named "default.css" will overwrite the builtin "default.css".
+html_static_path = ['_static']
+
+todo_include_todos = True
diff --git a/apps/cic-eth/doc/sphinx/index.rst b/apps/cic-eth/doc/sphinx/index.rst
new file mode 100644
index 00000000..f22a8a22
--- /dev/null
+++ b/apps/cic-eth/doc/sphinx/index.rst
@@ -0,0 +1,19 @@
+.. cic-indexer documentation master file, created by
+ sphinx-quickstart on Sun Sep 20 13:49:02 2020.
+ You can adapt this file completely to your liking, but it should at least
+ contain the root `toctree` directive.
+
+Welcome to cic-eth's documentation!
+===================================
+
+.. toctree::
+ :maxdepth: 2
+ :caption: Contents:
+
+
+Indices and tables
+==================
+
+* :ref:`genindex`
+* :ref:`modindex`
+* :ref:`search`
diff --git a/apps/cic-eth/doc/texinfo/old.20210107/Makefile b/apps/cic-eth/doc/texinfo/old.20210107/Makefile
new file mode 100644
index 00000000..0944d469
--- /dev/null
+++ b/apps/cic-eth/doc/texinfo/old.20210107/Makefile
@@ -0,0 +1,5 @@
+all: html
+
+.PHONY: html
+html:
+ makeinfo --html --output html index.texi
diff --git a/apps/cic-eth/doc/texinfo/old.20210107/api.texi b/apps/cic-eth/doc/texinfo/old.20210107/api.texi
new file mode 100644
index 00000000..46f3096d
--- /dev/null
+++ b/apps/cic-eth/doc/texinfo/old.20210107/api.texi
@@ -0,0 +1,34 @@
+@node Python API
+@chapter Python API
+
+@section Installation
+
+A @code{setuptools} file is provided to install @code{cic-eth} as a normal python package.
+
+The API will send tasks to the celery and immediately return task @code{uuid}. If an HTTP callback is provided, the result of the operation will be sent to it as a @code{POST} request with @code{application/json} content-type, with the following payload as pseudo-schema:
+
+@verbatim
+{
+ 'root': ,
+ 'status': ,
+ 'message': ,
+ 'result':
+}
+@end verbatim
+
+@subsection API calls
+
+Please refer to inline code docstrings in @file{cic_eth/api.py} for details on API function signatures and behaviors.
+
+@itemize
+@item
+@code{create_account(...)} - Create a new account and add the private key to the keystore
+@item
+@code{balance(...)} - Query the token balance of an address
+@item
+@code{transfer(...)} - Transfer tokens between addresses
+@item
+@code{convert(...)} - Convert between tokens for same address
+@item
+@code{convert_transfer(...)} - Convert tokens and send destination token to a specified address
+@end itemize
diff --git a/apps/cic-eth/doc/texinfo/old.20210107/index.texi b/apps/cic-eth/doc/texinfo/old.20210107/index.texi
new file mode 100644
index 00000000..793ef244
--- /dev/null
+++ b/apps/cic-eth/doc/texinfo/old.20210107/index.texi
@@ -0,0 +1,28 @@
+\input texinfo
+@settitle Grassroots Economics CIC ETH 0.4.1
+
+@copying
+Released 2020 under GPL3
+@end copying
+
+@titlepage
+@title Community Inclusion Currency Network
+@author Louis Holbrook
+
+@end titlepage
+
+@c
+@contents
+
+@ifnottex
+@node Top
+@top Grassroots Economics CIC ETH
+
+This document describes microservices that send transactions to and process events from an EVM blockchain.
+@end ifnottex
+
+
+@include overview.texi
+@include setup.texi
+@include run.texi
+@include api.texi
diff --git a/apps/cic-eth/doc/texinfo/old.20210107/overview.texi b/apps/cic-eth/doc/texinfo/old.20210107/overview.texi
new file mode 100644
index 00000000..216ddba2
--- /dev/null
+++ b/apps/cic-eth/doc/texinfo/old.20210107/overview.texi
@@ -0,0 +1,42 @@
+@node Overview
+@chapter Overview
+This is the core component for the CIC token network system. It provides a task worker infrastructure to interact with the Ethereum blockchain, aswell as daemons to monitor transactions.
+
+@section Reading this document
+
+Any paths in this document are relative to the root of the cic-eth git repository.
+
+@section Contents
+
+@itemize @bullet
+@item Python API that dispatches celery tasks for high-level actions
+@item Daemon for monitoring the state of and retrying outgoing transactions
+@item Daemon for monitoring new transactions of interest confirmed onchain
+@end itemize
+
+@section Dependencies
+
+Python dependencies can be acquired by running the usual python setup and/or using the provided requiremens.txt file.
+
+The application has the following non-python dependencies:
+
+@itemize @bullet
+@item
+@strong{PostgreSQL}: Database backend.
+@item
+@strong{Redis}: Broker and results for Celery workers.
+@item
+@strong{Bancor contracts}: A clone of the Bancor contact repository
+@item
+@strong{Ethereum node}: A synced ethereum node with keystore
+@end itemize
+
+@section Caveats
+
+The application @emph{must not} use private keys for which transactions may be generated from other sources.
+
+It application retrieves the transaction nonce for every transaction directly from the network. Any transaction submitted to it are passed on to the network with sequential nonces. The caller code needs to keep this in mind when considering whether to allow the account holder to submit additional transaction tasks before the current has been completed.
+
+@section Known issues
+
+The author has not yet figured out how to get @code{pytest-celery} to work with queues. Currently the functional tests hang when trying to run them.
diff --git a/apps/cic-eth/doc/texinfo/old.20210107/queue.texi b/apps/cic-eth/doc/texinfo/old.20210107/queue.texi
new file mode 100644
index 00000000..e69de29b
diff --git a/apps/cic-eth/doc/texinfo/old.20210107/run.texi b/apps/cic-eth/doc/texinfo/old.20210107/run.texi
new file mode 100644
index 00000000..a7ee7d9c
--- /dev/null
+++ b/apps/cic-eth/doc/texinfo/old.20210107/run.texi
@@ -0,0 +1,34 @@
+@node Running the application
+@chapter Running the application
+
+@section Celery worker
+
+The helper script @file{scripts/cic-eth-tasker.py} will connect to redis and the ethereum node and spawn a worker for all celery tasks.
+
+@section Transaction controller
+
+The celery task chains the process outgoing transactions only send the transactions to the network, after which their responsibility ends. And further processing is handled by @file{scripts/cic-eth-manager.py}.
+
+@subsection Monitor transaction state
+
+Records of transactions are added to the database, and the daemon looks for confirmations in block for these transaction, updating their state accordingly. The resulting state may @emph{only} by either @strong{SUCCESS} or @strong{REVERT}. A transaction is any of these states is finalized and won't be retried.
+
+@subsection Perform transfer after convert
+
+Handles the compound workflow where sender with token @code{A} wishes to send tokens to recipient with token @code{B}.
+
+The task worker only submits the convert transaction, because the actual amount of received tokens is not known before the convert takes place. The full amount of recevied tokens will be transferred after the successful convert.
+
+Convert-then-transfer tasks are recorded separately, and if the controller receive a confirmed convert transaction that has a local record, it submits a new transfer task to the task workers.
+
+@subsection Retry after timeout
+
+@strong{Not yet implemented!}.
+
+If a transaction lingers too long without being confirmed, the controller will attempt to re-submit the task and all its dependent tasks with a higher gas price.
+
+
+@section Transaction monitor
+
+@file{scripts/cic-eth-track.py} looks for token transfer or convert transaction for all known tokens on the network, and stores them in a local database cache.
+
diff --git a/apps/cic-eth/doc/texinfo/old.20210107/setup.texi b/apps/cic-eth/doc/texinfo/old.20210107/setup.texi
new file mode 100644
index 00000000..49cafb9d
--- /dev/null
+++ b/apps/cic-eth/doc/texinfo/old.20210107/setup.texi
@@ -0,0 +1,98 @@
+@node Setup
+@chapter Setup
+
+@section Prerequisites
+
+@itemize
+@item A running ETH provider with:
+@itemize
+@item Deployed bancor contracts
+@item Sufficient balances for system accounts
+@end itemize
+@item A running ETH signer provider, that can handle the following 'web3' JSON-RPC calls:
+@itemize
+@item @command{personal_newAccount}
+@item @command{eth_signTransaction}
+@end itemize
+@end itemize
+
+@section Database migration
+
+Execute @code{alembic upgrade head} in @file{cic_eth/db/migrations} to generate the schema in the database.
+
+@section Configuration settings
+
+@file{cic-eth} uses configuration files in @code{'ini'} format. All names are translated to upper case letters, and all values are concatenated to sections with a @key{_}. Example:
+
+@verbatim
+[foo]
+bar_baz = 42
+@end verbatim
+
+The above entry becomes @code{FOO_BAR_BAZ} with value @code{42}
+
+@subsection Database
+@table @code
+@item DATABASE_NAME
+@item DATABASE_USER
+@item DATABASE_PASSWORD
+@item DATABASE_HOST
+@item DATABASE_PORT
+Postgres database settings
+@end table
+
+@subsection Redis
+
+@table @code
+@item REDIS_BROKER_URL
+Redis settings
+@end table
+
+@subsection SSL
+
+@table @code
+@item SSL_ENABLE_CLIENT
+Use SSL client certification for outgoing web requests (boolean)
+@item SSL_CERT_FILE
+Absolute path to client certificate file
+@item SSL_KEY_FILE
+Absolute path to client key file
+@item SSL_PASSWORD
+Password to unlock client key
+@item SSL_CA_FILE
+The client certificate's authority chain
+@end table
+
+@subsection Ethereum
+
+@table @code
+@item ETH_PROVIDER
+URL to JSON-RPC API provider
+@item ETH_GAS_PROVIDER_ADDRESS
+Address providing gas to fund transactions for accounts in keystore
+@end table
+
+@subsection Bancor
+
+@table @code
+@item BANCOR_REGISTRY_ADDRESS
+Contract address for the ContractRegistry contract
+@item BANCOR_DIR
+Absolute path to root of the Bancor Solidity contract GIT repository
+@end table
+
+@subsection Syncer
+
+@table @code
+@item SYNCER_LOOP_DELAY
+Delay in seconds to wait between polls when no data has been found
+@end table
+
+@subsection Signer
+
+@table @code
+@item SIGNER_SECRET (development only)
+Key used by keystore to encrypt secrets
+@item SIGNER_PASSWORD
+Password for additional private key encryption on keystore
+@end table
diff --git a/apps/cic-eth/doc/texinfo/old.20210107/transactions.texi b/apps/cic-eth/doc/texinfo/old.20210107/transactions.texi
new file mode 100644
index 00000000..b6e48aa3
--- /dev/null
+++ b/apps/cic-eth/doc/texinfo/old.20210107/transactions.texi
@@ -0,0 +1,26 @@
+@chapter Transactions
+
+@section States
+
+@subsection Send transaction to network
+
+@multitable @columnfractions .35 .15 .15 .35
+@headitem Item @tab Exception @tab Action
+
+@item Chain node unreachable
+@tab ChainUnavailableError
+@tab Retry: unlimited, backoff
+
+@item Cannot save tx state to database
+@tab DatabaseUnavailableError
+@tab Crash: Notify by email
+
+@item Signer unreachable
+@tab SignerUnavailableError
+@tab Retry: unlimited, backoff
+
+@item Unknown address
+@tab SignerAccountUnknownError
+@tab Fail
+
+
diff --git a/apps/cic-eth/doc/texinfo/overview.texi b/apps/cic-eth/doc/texinfo/overview.texi
new file mode 100644
index 00000000..46d36f0d
--- /dev/null
+++ b/apps/cic-eth/doc/texinfo/overview.texi
@@ -0,0 +1,24 @@
+@node cic-eth
+@chapter cic-eth
+
+@section Overview
+
+@code{cic-eth} is the heart of the custodial account component. It is a combination of python-celery task queues and daemons that sign, dispatch and monitor blockchain transactions, aswell as triggering tasks contingent on other transactions.
+
+@subsection Dependencies
+
+The @code{cic-registry} module is used as a cache for contracts and tokens on the network.
+
+A web3 JSON-RPC service that transparently proxies a keystore and provides transaction and message signing. The current development version uses the python web3 middleware feature to route methodsi involving the keystore to the module @code{crypto-dev-signer}, which is hosted on @file{pypi.org}.
+
+@subsection What does it do
+
+
+
+@subsection Tasks
+
+Two main categories exist for tasks, @code{eth} and @code{queue}.
+
+The @code{eth} tasks provide means to construct and decode Ethereum transactions, as well as interfacing the underlying key store.
+
+Tasks in the @code{queue} module operate on the state of transactions queued for processing by @code{cic-eth}.
diff --git a/apps/cic-eth/docker/Dockerfile b/apps/cic-eth/docker/Dockerfile
new file mode 100644
index 00000000..88dfea8c
--- /dev/null
+++ b/apps/cic-eth/docker/Dockerfile
@@ -0,0 +1,43 @@
+# FROM grassrootseconomics:cic
+
+#FROM python:3.8.6-alpine
+FROM python:3.8.6-slim-buster
+
+#COPY --from=0 /usr/local/share/cic/solidity/ /usr/local/share/cic/solidity/
+
+WORKDIR /usr/src/cic-eth
+
+ARG pip_extra_index_url_flag='--index https://pypi.org/simple --extra-index-url https://pip.grassrootseconomics.net:8433'
+ARG root_requirement_file='requirements.txt'
+
+#RUN apk update && \
+# apk add gcc musl-dev gnupg libpq
+#RUN apk add postgresql-dev
+#RUN apk add linux-headers
+#RUN apk add libffi-dev
+RUN apt-get update && \
+ apt install -y gcc gnupg libpq-dev wget make g++ gnupg bash procps
+
+# Copy shared requirements from top of mono-repo
+RUN echo "copying root req file ${root_requirement_file}"
+COPY $root_requirement_file .
+RUN pip install -r $root_requirement_file $pip_extra_index_url_flag
+
+COPY cic-eth/scripts/ scripts/
+COPY cic-eth/setup.cfg cic-eth/setup.py ./
+COPY cic-eth/cic_eth/ cic_eth/
+# Copy app specific requirements
+COPY cic-eth/requirements.txt .
+COPY cic-eth/test_requirements.txt .
+RUN pip install $pip_extra_index_url_flag .
+
+COPY cic-eth/docker/* ./
+RUN chmod 755 *.sh
+COPY cic-eth/tests/ tests/
+
+# # ini files in config directory defines the configurable parameters for the application
+# # they can all be overridden by environment variables
+# # to generate a list of environment variables from configuration, use: confini-dump -z (executable provided by confini package)
+COPY cic-eth/config/ /usr/local/etc/cic-eth/
+COPY cic-eth/cic_eth/db/migrations/ /usr/local/share/cic-eth/alembic/
+COPY cic-eth/crypto_dev_signer_config/ /usr/local/etc/crypto-dev-signer/
diff --git a/apps/cic-eth/docker/db.sh b/apps/cic-eth/docker/db.sh
new file mode 100644
index 00000000..bc239cf6
--- /dev/null
+++ b/apps/cic-eth/docker/db.sh
@@ -0,0 +1,4 @@
+#!/bin/bash
+
+migrate.py -c /usr/local/etc/cic-eth --migrations-dir /usr/local/share/cic-eth/alembic -vv
+
diff --git a/apps/cic-eth/docker/start_dispatcher.sh b/apps/cic-eth/docker/start_dispatcher.sh
new file mode 100644
index 00000000..86ac06f7
--- /dev/null
+++ b/apps/cic-eth/docker/start_dispatcher.sh
@@ -0,0 +1,5 @@
+#!/bin/bash
+
+. ./db.sh
+
+/usr/local/bin/cic-eth-dispatcher $@
diff --git a/apps/cic-eth/docker/start_manager.sh b/apps/cic-eth/docker/start_manager.sh
new file mode 100644
index 00000000..383e888d
--- /dev/null
+++ b/apps/cic-eth/docker/start_manager.sh
@@ -0,0 +1,5 @@
+#!/bin/bash
+
+. ./db.sh
+
+/usr/local/bin/cic-eth-manager $@
diff --git a/apps/cic-eth/docker/start_retry.sh b/apps/cic-eth/docker/start_retry.sh
new file mode 100644
index 00000000..721d5bcf
--- /dev/null
+++ b/apps/cic-eth/docker/start_retry.sh
@@ -0,0 +1,5 @@
+#!/bin/bash
+
+. ./db.sh
+
+/usr/local/bin/cic-eth-retrier $@
diff --git a/apps/cic-eth/docker/start_tasker.sh b/apps/cic-eth/docker/start_tasker.sh
new file mode 100644
index 00000000..0dc729ac
--- /dev/null
+++ b/apps/cic-eth/docker/start_tasker.sh
@@ -0,0 +1,29 @@
+#!/bin/bash
+
+. ./db.sh
+
+# set CONFINI_ENV_PREFIX to override the env prefix to override env vars
+
+echo "!!! starting signer"
+python /usr/local/bin/crypto-dev-daemon -vv -c /usr/local/etc/crypto-dev-signer &
+
+echo "!!! starting tracker"
+/usr/local/bin/cic-eth-tasker $@
+
+# thanks! https://docs.docker.com/config/containers/multi-service_container/
+sleep 1;
+echo "!!! entering monitor loop"
+while true; do
+ ps aux | grep crypto-dev-daemon | grep -q -v grep
+ PROCESS_1_STATUS=$?
+ ps aux | grep cic-eth-tasker |grep -q -v grep
+ PROCESS_2_STATUS=$?
+ # If the greps above find anything, they exit with 0 status
+ # If they are not both 0, then something is wrong
+ if [ $PROCESS_1_STATUS -ne 0 -o $PROCESS_2_STATUS -ne 0 ]; then
+ echo "One of the processes has already exited."
+ exit 1
+ fi
+ sleep 15;
+done
+
diff --git a/apps/cic-eth/examples/api_callback.py b/apps/cic-eth/examples/api_callback.py
new file mode 100644
index 00000000..20eaa469
--- /dev/null
+++ b/apps/cic-eth/examples/api_callback.py
@@ -0,0 +1,76 @@
+# standard imports
+import logging
+import uuid
+import socket
+
+# third-party imports
+import celery
+import redis
+
+# local imports
+import cic_eth
+
+logging.basicConfig(level=logging.DEBUG)
+logg = logging.getLogger()
+
+celery_app = celery.Celery(broker='redis://')
+
+uu = uuid.uuid4()
+
+r = redis.Redis()
+r_key = '{}-results'.format(uu)
+
+c = 3
+results = []
+for i in range(c):
+ x = uuid.uuid4()
+ results.append(str(x))
+
+
+@celery_app.task(queue=str(uu), names='customcustom')
+def custom_callback(result_from_chain, static_param_from_api, status_code_from_chain=0, message_from_chain={}):
+ global c
+
+ r.rpush(r_key, result_from_chain)
+ l = r.llen(r_key)
+ logg.debug('i {} l {} result {} url {} statuscode {} message {}'.format(
+ i,
+ l,
+ result_from_chain,
+ static_param_from_api,
+ status_code_from_chain,
+ message_from_chain,
+ )
+ )
+ if l == c:
+ r.delete(r_key)
+ celery_app.control.broadcast('shutdown', destination=['{}@{}'.format(uu, socket.gethostname())])
+
+
+@celery_app.task(queue=str(uu), name='dodorunrunrun')
+def custom_run(results):
+ for z in results:
+ logg.debug('sending {}'.format(z))
+ a = cic_eth.Api(callback_param=uu, callback_task=custom_callback)
+ a.ping(z)
+
+
+if __name__ == '__main__':
+ r.delete(r_key)
+ s = celery.signature(
+ 'dodorunrunrun',
+ [results],
+ queue=str(uu),
+ )
+ s.apply_async()
+
+ worker = celery_app.worker_main(
+ [
+ 'api_callback',
+ '--loglevel=DEBUG',
+ '-n',
+ '{}@%h'.format(uu),
+ '-Q',
+ str(uu),
+ ],
+ )
diff --git a/apps/cic-eth/requirements.txt b/apps/cic-eth/requirements.txt
new file mode 100644
index 00000000..15c397bf
--- /dev/null
+++ b/apps/cic-eth/requirements.txt
@@ -0,0 +1,18 @@
+web3==5.12.2
+celery==4.4.7
+crypto-dev-signer~=0.4.13b13
+confini~=0.3.6b1
+cic-registry~=0.5.3a10
+cic-bancor~=0.0.6
+redis==3.5.3
+alembic==1.4.2
+websockets==8.1
+requests~=2.24.0
+eth_accounts_index~=0.0.10a5
+erc20-approval-escrow~=0.3.0a3
+erc20-single-shot-faucet~=0.2.0a4
+rlp==2.0.1
+uWSGI==2.0.19.1
+semver==2.13.0
+eth-gas-proxy==0.0.1a4
+websocket-client==0.57.0
diff --git a/apps/cic-eth/scripts/generator.py b/apps/cic-eth/scripts/generator.py
new file mode 100644
index 00000000..4e939663
--- /dev/null
+++ b/apps/cic-eth/scripts/generator.py
@@ -0,0 +1,181 @@
+import os
+import logging
+import random
+import alembic
+import argparse
+import datetime
+import hashlib
+import math
+
+import confini
+
+from cic_eth.db import SessionBase
+from cic_eth.db import dsn_from_config
+from cic_eth.db.enum import StatusEnum
+from cic_eth.db.models.tx import Tx
+from cic_eth.db.models.tx import TxCache
+from cic_eth.db.models.otx import Otx
+from cic_eth.db.models.otx import Otx
+
+
+# connect to database
+dsn = dsn_from_config(config)
+SessionBase.connect(dsn)
+
+pending_states = [
+ StatusEnum.PENDING,
+ StatusEnum.SENDFAIL,
+ StatusEnum.WAITFORGAS,
+ ]
+
+synced_states = [
+ StatusEnum.SENT,
+ StatusEnum.CANCELLED,
+ ]
+
+failed_states = [
+ StatusEnum.REJECTED,
+ StatusEnum.FUBAR,
+ ]
+
+mined_states = [
+ StatusEnum.REVERTED,
+ StatusEnum.SUCCESS,
+ ]
+
+all_states = pending_states + synced_states + failed_states + mined_states
+
+
+class MalarkeyCommitter():
+ """Adds entries to the cic-eth transaction cache backend.
+
+ All values generated by this class are deterministic but completely arbitrary.
+
+ :param generator: Generator instance used to generate the transactions
+ :type generator: Generator
+ :param block_change_factor: Probabiliy of advancing to next block per entry (Optional; default: 0.6)
+ :type block_change_factor: float
+ :param tx_index_max: Maximum transaction index number to generate (Optional; default: 200)
+ :type ix_index_max: int
+ :param block_time_seconds: Seconds to advance block timestamp datetime on block advance
+ :type block_time_seconds: int
+ """
+ def __init__(self, generator, block_change_factor=0.6, tx_index_max=200, block_time_seconds=15):
+ self.g = generator
+ self.s = SessionBase.create_session()
+ self.datetime = datetime.datetime.utcnow()
+ self.block = 0
+ self.tx = 0
+ self.block_change_factor = block_change_factor
+ self.tx_index_max = tx_index_max
+ self.block_time_seconds = block_time_seconds
+
+
+ def advance(self):
+ """Randomly advances block number and transaction index.
+ """
+ if random.random() < self.block_change_factor:
+ self.block_advance()
+ tx_advance = random.randint(0, self.tx_index_max - self.tx)
+ self.tx_advance(tx_advance)
+
+
+ def tx_advance(self, n=1):
+ """Advance tx index number.
+
+ :param n: Will be added to tx index (Optional; default: 1)
+ :type n: int
+ """
+ self.tx += n
+
+
+ def block_advance(self, n=1):
+ """Advance block number.
+
+ :param n: Will be added to tx index (Optional; default: 1)
+ :type n: int
+ """
+ self.block += n
+ self.datetime += datetime.timedelta(seconds=self.block_time_seconds)
+ self.tx = 0
+
+
+ def stamp(self, entry):
+ """Calls the random advance method, and sets the corresponding block, tx index and dates on the entry.
+ """
+ self.advance()
+ entry.mine(self.block, self.tx, self.datetime)
+
+
+ def commit_func(self, entry):
+ """Implements interface needed for GeneratorSession.commit_func, storing a given entry.
+
+ Generates random block and tx index for entry, advancing date correspondingly.
+
+ Also generates random transaction queue states for the entries:
+
+ - For any entry with foreign origin, queue state will always be in the set of "mined" states if applicable.
+ - For any entry with local origin and "mined" queue state, an incoming transaction record will be added.
+
+ :param entry: Entry to commit
+ :type entry: GeneratorEntry
+ """
+ self.stamp(entry)
+ nonce = self.g.get_nonce(entry.sender)
+ tx_hash = '0x{:064x}'.format(random.getrandbits(256))
+ signed_tx_bytes = b''
+ h = hashlib.sha256()
+ for i in range(4):
+ h.update(tx_hash.encode('utf-8'))
+ signed_tx_bytes += h.digest()
+ signed_tx = '0x' + signed_tx_bytes.hex()
+
+ state = None
+ if entry.sender in self.g.addresses['foreign']:
+ state = random.choice(mined_states)
+ else:
+ state = random.choice(all_states)
+
+ otx = None
+ tx = None
+
+ if entry.sender in self.g.addresses['local']:
+ otx = Otx(
+ nonce,
+ entry.sender,
+ tx_hash,
+ signed_tx,
+ )
+ otx.status = state
+ self.s.add(otx)
+ self.s.flush()
+
+ if state in mined_states:
+ tx = Tx(
+ tx_hash,
+ state == StatusEnum.SUCCESS,
+ )
+ self.s.add(tx)
+ self.s.flush()
+
+ self.s.commit()
+
+ txc = TxCache(
+ tx_hash,
+ entry.sender,
+ entry.recipient,
+ entry.source_token,
+ entry.destination_token,
+ entry.from_value,
+ entry.to_value,
+ entry.block,
+ entry.tx,
+ entry.sender in self.g.addresses['local'],
+ )
+ txc.date_registered = entry.datetime
+ self.s.add(txc)
+ self.s.commit()
+
+ logg.info('committed {}'.format(entry))
+
+
diff --git a/apps/cic-eth/scripts/insert_tx.py b/apps/cic-eth/scripts/insert_tx.py
new file mode 100644
index 00000000..1a9727b7
--- /dev/null
+++ b/apps/cic-eth/scripts/insert_tx.py
@@ -0,0 +1,57 @@
+# standard imports
+import os
+import sys
+import logging
+import time
+import argparse
+
+# third-party imports
+import confini
+import celery
+
+# local imports
+import cic_eth
+from cic_eth import db
+from cic_eth import eth
+from cic_eth.eth.token import transfer
+
+logging.basicConfig(level=logging.WARNING)
+logg = logging.getLogger()
+
+app = celery.Celery(backend='redis://', broker='redis://')
+
+if __name__ == '__main__':
+
+ config_dir = os.path.join('/etc/cic-eth/watcher')
+
+ argparser = argparse.ArgumentParser(description='daemon that monitors transactions in new blocks')
+ argparser.add_argument('-c', type=str, default=config_dir, help='config root to use')
+ argparser.add_argument('-v', help='be verbose', action='store_true')
+ argparser.add_argument('-vv', help='be more verbose', action='store_true')
+ args = argparser.parse_args(sys.argv[1:])
+
+ config_dir = os.path.join(args.c)
+ os.makedirs(config_dir, 0o777, True)
+
+ if args.v == True:
+ logging.getLogger().setLevel(logging.INFO)
+ elif args.vv == True:
+ logging.getLogger().setLevel(logging.DEBUG)
+
+ config = confini.Config(config_dir)
+ config.process()
+ logg.debug('config loaded from {}'.format(config_dir))
+
+ token_address = '0x528c3E8B3e6dC646530440D88F83da0e45DaC25b'
+ #sender = '0xa2e85B7F1d61522A88f446C52D09F724C807d7ad'
+ sender = '0xc14958CD9A605AB0d9A36850362AaD2b9D42DF97'
+ recipient = '0xe3C4db5947409Aff0FF8D643047EA41515cA4B8e'
+
+ transfer.delay(
+ [{
+ 'address': token_address
+ }],
+ sender,
+ recipient,
+ 1000000000000000000000,
+ )
diff --git a/apps/cic-eth/scripts/migrate.py b/apps/cic-eth/scripts/migrate.py
new file mode 100644
index 00000000..4a2c0139
--- /dev/null
+++ b/apps/cic-eth/scripts/migrate.py
@@ -0,0 +1,56 @@
+#!/usr/bin/python
+import os
+import argparse
+import logging
+
+import alembic
+from alembic.config import Config as AlembicConfig
+import confini
+
+from cic_eth.db import dsn_from_config
+
+logging.basicConfig(level=logging.WARNING)
+logg = logging.getLogger()
+
+# BUG: the dbdir doesn't work after script install
+rootdir = os.path.dirname(os.path.dirname(os.path.realpath(__file__)))
+dbdir = os.path.join(rootdir, 'cic_eth', 'db')
+migrationsdir = os.path.join(dbdir, 'migrations')
+
+config_dir = os.path.join('/usr/local/etc/cic-eth')
+
+argparser = argparse.ArgumentParser()
+argparser.add_argument('-c', type=str, default=config_dir, help='config file')
+argparser.add_argument('--env-prefix', default=os.environ.get('CONFINI_ENV_PREFIX'), dest='env_prefix', type=str, help='environment prefix for variables to overwrite configuration')
+argparser.add_argument('--migrations-dir', dest='migrations_dir', default=migrationsdir, type=str, help='path to alembic migrations directory')
+argparser.add_argument('-v', action='store_true', help='be verbose')
+argparser.add_argument('-vv', action='store_true', help='be more verbose')
+args = argparser.parse_args()
+
+if args.vv:
+ logging.getLogger().setLevel(logging.DEBUG)
+elif args.v:
+ logging.getLogger().setLevel(logging.INFO)
+
+config = confini.Config(args.c, args.env_prefix)
+config.process()
+config.censor('PASSWORD', 'DATABASE')
+config.censor('PASSWORD', 'SSL')
+logg.debug('config:\n{}'.format(config))
+
+migrations_dir = os.path.join(args.migrations_dir, config.get('DATABASE_ENGINE'))
+if not os.path.isdir(migrations_dir):
+ logg.debug('migrations dir for engine {} not found, reverting to default'.format(config.get('DATABASE_ENGINE')))
+ migrations_dir = os.path.join(args.migrations_dir, 'default')
+
+# connect to database
+dsn = dsn_from_config(config)
+
+
+logg.info('using migrations dir {}'.format(migrations_dir))
+logg.info('using db {}'.format(dsn))
+ac = AlembicConfig(os.path.join(migrations_dir, 'alembic.ini'))
+ac.set_main_option('sqlalchemy.url', dsn)
+ac.set_main_option('script_location', migrations_dir)
+
+alembic.command.upgrade(ac, 'head')
diff --git a/apps/cic-eth/setup.cfg b/apps/cic-eth/setup.cfg
new file mode 100644
index 00000000..5d5a5c4a
--- /dev/null
+++ b/apps/cic-eth/setup.cfg
@@ -0,0 +1,49 @@
+[metadata]
+name = cic-eth
+version = attr: cic_eth.version.__version_string__
+description = CIC Network Ethereum interaction
+author = Louis Holbrook
+author_email = dev@holbrook.no
+url = https://gitlab.com/grassrootseconomics/cic-eth
+keywords =
+ cic
+ cryptocurrency
+ ethereum
+classifiers =
+ Programming Language :: Python :: 3
+ Operating System :: OS Independent
+ Development Status :: 3 - Alpha
+ Environment :: No Input/Output (Daemon)
+ Intended Audience :: Developers
+ License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)
+ Topic :: Internet
+# Topic :: Blockchain :: EVM
+license = GPL3
+licence_files =
+ LICENSE.txt
+
+[options]
+python_requires = >= 3.6
+packages =
+ cic_eth
+ cic_eth.admin
+ cic_eth.eth
+ cic_eth.api
+ cic_eth.db
+ cic_eth.db.models
+ cic_eth.queue
+ cic_eth.sync
+ cic_eth.runnable
+ cic_eth.callbacks
+scripts =
+ ./scripts/migrate.py
+
+[options.entry_points]
+console_scripts =
+ cic-eth-tasker = cic_eth.runnable.tasker:main
+ cic-eth-manager = cic_eth.runnable.manager:main
+ cic-eth-tag = cic_eth.runnable.tag:main
+ cic-eth-dispatcher = cic_eth.runnable.dispatcher:main
+ cic-eth-retrier = cic_eth.runnable.retry:main
+ cic-eth-inspect = cic_eth.runnable.view:main
+ cic-eth-ctl = cic_eth.runnable.ctrl:main
diff --git a/apps/cic-eth/setup.py b/apps/cic-eth/setup.py
new file mode 100644
index 00000000..624baab4
--- /dev/null
+++ b/apps/cic-eth/setup.py
@@ -0,0 +1,27 @@
+from setuptools import setup
+import configparser
+import os
+
+requirements = []
+f = open('requirements.txt', 'r')
+while True:
+ l = f.readline()
+ if l == '':
+ break
+ requirements.append(l.rstrip())
+f.close()
+
+test_requirements = []
+f = open('test_requirements.txt', 'r')
+while True:
+ l = f.readline()
+ if l == '':
+ break
+ test_requirements.append(l.rstrip())
+f.close()
+
+
+setup(
+ install_requires=requirements,
+ tests_require=test_requirements,
+ )
diff --git a/apps/cic-eth/test_requirements.txt b/apps/cic-eth/test_requirements.txt
new file mode 100644
index 00000000..d168bb66
--- /dev/null
+++ b/apps/cic-eth/test_requirements.txt
@@ -0,0 +1,7 @@
+pytest==6.0.1
+pytest-celery==0.0.0a1
+pytest-mock==3.3.1
+py-eth==0.1.1
+pytest-cov==2.10.1
+eth-tester==0.5.0b3
+py-evm==0.3.0a20
diff --git a/apps/cic-eth/tests/conftest.py b/apps/cic-eth/tests/conftest.py
new file mode 100644
index 00000000..aa6df8ba
--- /dev/null
+++ b/apps/cic-eth/tests/conftest.py
@@ -0,0 +1,47 @@
+# standard imports
+import os
+import logging
+import sys
+
+# third-party imports
+import pytest
+from cic_registry import CICRegistry
+
+script_dir = os.path.dirname(os.path.realpath(__file__))
+root_dir = os.path.dirname(script_dir)
+sys.path.insert(0, root_dir)
+data_dir = os.path.join(script_dir, 'testdata', 'abi')
+CICRegistry.add_path(data_dir)
+
+# fixtures
+from tests.fixtures_registry import *
+from cic_registry.pytest import *
+from cic_bancor.pytest import *
+from tests.fixtures_config import *
+from tests.fixtures_celery import *
+from tests.fixtures_web3 import *
+from tests.fixtures_database import *
+from tests.fixtures_faucet import *
+from tests.fixtures_transferapproval import *
+from tests.fixtures_account import *
+
+logg = logging.getLogger()
+
+
+@pytest.fixture(scope='session')
+def init_registry(
+ init_w3_conn,
+ ):
+ return CICRegistry
+
+
+@pytest.fixture(scope='function')
+def eth_empty_accounts(
+ init_wallet_extension,
+ ):
+ a = []
+ for i in range(10):
+ address = init_wallet_extension.new_account()
+ a.append(address)
+ logg.info('added address {}'.format(a))
+ return a
diff --git a/apps/cic-eth/tests/fixtures_account.py b/apps/cic-eth/tests/fixtures_account.py
new file mode 100644
index 00000000..9fbe7899
--- /dev/null
+++ b/apps/cic-eth/tests/fixtures_account.py
@@ -0,0 +1,30 @@
+# standard imports
+import logging
+
+# third-party imports
+import pytest
+from eth_accounts_index import AccountRegistry
+from cic_registry import CICRegistry
+
+logg = logging.getLogger(__name__)
+
+
+@pytest.fixture(scope='session')
+def accounts_registry(
+ default_chain_spec,
+ cic_registry,
+ w3,
+ ):
+ abi = AccountRegistry.abi()
+ constructor = w3.eth.contract(abi=abi, bytecode=AccountRegistry.bytecode())
+ tx_hash = constructor.constructor().transact()
+ r = w3.eth.getTransactionReceipt(tx_hash)
+ logg.debug('accounts registry deployed {}'.format(r.contractAddress))
+ account_registry = AccountRegistry(w3, r.contractAddress)
+
+ c = w3.eth.contract(abi=abi, address=r.contractAddress)
+ c.functions.addWriter(w3.eth.accounts[0]).transact()
+
+ CICRegistry.add_contract(default_chain_spec, c, 'AccountRegistry')
+
+ return account_registry
diff --git a/apps/cic-eth/tests/fixtures_bancor.py b/apps/cic-eth/tests/fixtures_bancor.py
new file mode 100644
index 00000000..9d973a31
--- /dev/null
+++ b/apps/cic-eth/tests/fixtures_bancor.py
@@ -0,0 +1,234 @@
+# standard imports
+import os
+import logging
+import json
+
+# third-party imports
+import pytest
+from cic_registry.bancor import contract_ids
+from cic_registry import bancor
+
+# local imports
+from cic_eth.eth import rpc
+
+script_dir = os.path.dirname(os.path.realpath(__file__))
+root_dir = os.path.dirname(script_dir)
+
+logg = logging.getLogger(__file__)
+
+
+class BancorContractLoader:
+
+ bancor_path = os.path.join(root_dir, 'bancor')
+ registry_contract = None
+
+ @staticmethod
+ def build_path():
+ return BancorContractLoader.bancor_path
+# return os.path.join(BancorContractLoader.bancor_path, 'solidity', 'build', 'contracts')
+
+
+ @staticmethod
+ def contract(w3, bundle_id, registry_id=None):
+ if registry_id == None:
+ registry_id = bundle_id
+ contract_id_hex = w3.toHex(text=registry_id)
+ contract_address = BancorContractLoader.registry_contract.functions.addressOf(contract_id_hex).call()
+ contract_build_file = os.path.join(
+ BancorContractLoader.build_path(),
+ '{}.json'.format(bundle_id),
+ )
+ f = open(os.path.join(contract_build_file))
+ j = json.load(f)
+ f.close()
+ contract_abi = j['abi']
+ logg.debug('creating contract interface {} ({}) at address {}'.format(registry_id, bundle_id, contract_address))
+ contract = w3.eth.contract(abi=contract_abi, address=contract_address)
+ return contract
+
+
+
+# TODO: DRY
+@pytest.fixture(scope='session')
+def bancor_deploy(
+ load_config,
+ init_w3_conn,
+ ):
+ bancor_dir_default = os.path.join(root_dir, 'bancor')
+ logg.debug('bancor deploy "{}"'.format(bancor_dir_default))
+ BancorContractLoader.bancor_path = load_config.get('BANCOR_DIR', bancor_dir_default)
+ bancor_build_dir = BancorContractLoader.build_path()
+
+ # deploy registry
+ registry_build_file = os.path.join(bancor_build_dir, 'ContractRegistry.json')
+ f = open(os.path.join(registry_build_file))
+ j = json.load(f)
+ f.close()
+ registry_constructor = init_w3_conn.eth.contract(abi=j['abi'], bytecode=j['bytecode'])
+ tx = registry_constructor.constructor().transact()
+ rcpt = init_w3_conn.eth.getTransactionReceipt(tx)
+ registry_address = rcpt['contractAddress']
+ registry_contract = init_w3_conn.eth.contract(abi=j['abi'], address=registry_address)
+ BancorContractLoader.registry_contract = registry_contract
+
+ # deply reserve token
+ reservetoken_build_file = os.path.join(bancor_build_dir, 'EtherToken.json')
+ f = open(os.path.join(reservetoken_build_file))
+ j = json.load(f)
+ f.close()
+ reservetoken_constructor = init_w3_conn.eth.contract(abi=j['abi'], bytecode=j['bytecode'])
+ tx = reservetoken_constructor.constructor('Reserve', 'RSV').transact()
+ rcpt = init_w3_conn.eth.getTransactionReceipt(tx)
+ reservetoken_address = rcpt['contractAddress']
+ reservetoken_contract = init_w3_conn.eth.contract(abi=j['abi'], address=reservetoken_address)
+
+ # register reserve token as bancor hub token
+ key_hex = init_w3_conn.toHex(text='BNTToken')
+ registry_contract.functions.registerAddress(key_hex, reservetoken_address).transact()
+
+ # deposit balances for minting liquid tokens with reserve
+ init_w3_conn.eth.sendTransaction({
+ 'from': init_w3_conn.eth.accounts[1],
+ 'to': reservetoken_address,
+ 'value': init_w3_conn.toWei('101', 'ether'),
+ 'nonce': 0,
+ })
+ init_w3_conn.eth.sendTransaction({
+ 'from': init_w3_conn.eth.accounts[2],
+ 'to': reservetoken_address,
+ 'value': init_w3_conn.toWei('101', 'ether'),
+ 'nonce': 0,
+ })
+
+ # deploy converter factory contract for creating liquid token exchanges
+ build_file = os.path.join(bancor_build_dir, 'LiquidTokenConverterFactory.json')
+ f = open(build_file)
+ j = json.load(f)
+ f.close()
+ converterfactory_constructor = init_w3_conn.eth.contract(abi=j['abi'], bytecode=j['bytecode'])
+ tx = converterfactory_constructor.constructor().transact()
+ rcpt = init_w3_conn.eth.getTransactionReceipt(tx)
+ converter_factory_address = rcpt['contractAddress']
+
+ # deploy the remaining contracts managed by the registry
+ for k in contract_ids.keys():
+ build_file = os.path.join(bancor_build_dir, '{}.json'.format(k))
+ f = open(build_file)
+ j = json.load(f)
+ f.close()
+ contract_constructor = init_w3_conn.eth.contract(abi=j['abi'], bytecode=j['bytecode'])
+ tx = None
+
+ # include the registry address as constructor parameters for the contracts that require it
+ if k in ['ConverterRegistry', 'ConverterRegistryData', 'BancorNetwork', 'ConversionPathFinder']:
+ tx = contract_constructor.constructor(registry_address).transact()
+ else:
+ tx = contract_constructor.constructor().transact()
+ rcpt = init_w3_conn.eth.getTransactionReceipt(tx)
+ contract_address = rcpt['contractAddress']
+
+ # register contract in registry
+ key_hex = init_w3_conn.toHex(text=contract_ids[k])
+ registry_contract.functions.registerAddress(key_hex, contract_address).transact()
+ contract = init_w3_conn.eth.contract(abi=j['abi'], address=contract_address)
+
+ # bancor formula needs to be initialized before use
+ if k == 'BancorFormula':
+ logg.debug('init bancor formula {}'.format(contract_address))
+ contract.functions.init().transact()
+
+ # converter factory needs liquid token converter factory to be able to issue our liquid tokens
+ if k == 'ConverterFactory':
+ logg.debug('register converter factory {}'.format(converter_factory_address))
+ contract.functions.registerTypedConverterFactory(converter_factory_address).transact()
+
+ logg.info('deployed registry at address {}'.format(registry_address))
+ return registry_contract
+
+
+
+def __create_converter(w3, converterregistry_contract, reserve_address, owner_address, token_name, token_symbol):
+ converterregistry_contract.functions.newConverter(
+ 0,
+ token_name,
+ token_symbol,
+ 18,
+ 100000,
+ [reserve_address],
+ [250000],
+ ).transact({
+ 'from': owner_address,
+ })
+
+
+@pytest.fixture(scope='session')
+def tokens_to_deploy(
+ ):
+ return [
+ (1, 'Bert Token', 'BRT'), # account_index, token name, token symbol
+ (2, 'Ernie Token', 'RNI'),
+ ]
+
+
+@pytest.fixture(scope='session')
+def bancor_tokens(
+ init_w3_conn,
+ bancor_deploy,
+ tokens_to_deploy,
+ ):
+
+ registry_contract = bancor_deploy
+
+ reserve_contract = BancorContractLoader.contract(init_w3_conn, 'ERC20Token', 'BNTToken')
+ reserve_address = reserve_contract.address
+
+ network_id = init_w3_conn.toHex(text='BancorNetwork')
+ network_address = registry_contract.functions.addressOf(network_id).call()
+
+ converterregistry_contract = BancorContractLoader.contract(init_w3_conn, 'ConverterRegistry', 'BancorConverterRegistry')
+
+ for p in tokens_to_deploy:
+ __create_converter(init_w3_conn, converterregistry_contract, reserve_address, init_w3_conn.eth.accounts[p[0]], p[1], p[2])
+
+ tokens = converterregistry_contract.functions.getAnchors().call()
+
+ network_contract = BancorContractLoader.contract(init_w3_conn, 'BancorNetwork')
+
+ mint_amount = init_w3_conn.toWei('100', 'ether')
+ i = 0
+ for token in tokens:
+ i += 1
+ owner = init_w3_conn.eth.accounts[i]
+ logg.debug('owner {} is {}'.format(owner, token))
+ reserve_contract.functions.approve(network_address, 0).transact({
+ 'from': owner
+ })
+ reserve_contract.functions.approve(network_address, mint_amount).transact({
+ 'from': owner
+ })
+ logg.debug('convert {} {} {} {}'.format(reserve_address, token, mint_amount, owner))
+ network_contract.functions.convert([
+ reserve_address,
+ token,
+ token,
+ ],
+ mint_amount,
+ mint_amount,
+ ).transact({
+ 'from': owner,
+ })
+
+ return tokens
+
+
+@pytest.fixture(scope='session')
+def bancor_load(
+ load_config,
+ init_w3_conn,
+ bancor_deploy,
+ bancor_tokens,
+ ):
+ registry_address = bancor_deploy.address
+ bancor_dir_default = os.path.join(root_dir, 'bancor')
+ bancor_dir = load_config.get('BANCOR_DIR', bancor_dir_default)
+ bancor.load(init_w3_conn, registry_address, bancor_dir)
diff --git a/apps/cic-eth/tests/fixtures_celery.py b/apps/cic-eth/tests/fixtures_celery.py
new file mode 100644
index 00000000..a57c6b94
--- /dev/null
+++ b/apps/cic-eth/tests/fixtures_celery.py
@@ -0,0 +1,57 @@
+# third-party imports
+import pytest
+import tempfile
+import logging
+import shutil
+
+logg = logging.getLogger(__name__)
+
+
+# celery fixtures
+@pytest.fixture(scope='session')
+def celery_includes():
+ return [
+ 'cic_eth.eth.bancor',
+ 'cic_eth.eth.token',
+ 'cic_eth.eth.request',
+ 'cic_eth.eth.tx',
+ 'cic_eth.queue.tx',
+ 'cic_eth.admin.ctrl',
+ 'cic_eth.admin.nonce',
+ 'cic_eth.eth.account',
+ 'cic_eth.callbacks.noop',
+ 'cic_eth.callbacks.http',
+ ]
+
+
+@pytest.fixture(scope='session')
+def celery_config():
+ bq = tempfile.mkdtemp()
+ bp = tempfile.mkdtemp()
+ rq = tempfile.mkdtemp()
+ logg.debug('celery broker queue {} processed {}'.format(bq, bp))
+ logg.debug('celery backend store {}'.format(rq))
+ yield {
+ 'broker_url': 'filesystem://',
+ 'broker_transport_options': {
+ 'data_folder_in': bq,
+ 'data_folder_out': bq,
+ 'data_folder_processed': bp,
+ },
+ 'result_backend': 'file://{}'.format(rq),
+ }
+ logg.debug('cleaning up celery filesystem backend files {} {} {}'.format(bq, bp, rq))
+ shutil.rmtree(bq)
+ shutil.rmtree(bp)
+ shutil.rmtree(rq)
+
+
+@pytest.fixture(scope='session')
+def celery_worker_parameters():
+ return {
+# 'queues': ('cic-eth'),
+ }
+
+@pytest.fixture(scope='session')
+def celery_enable_logging():
+ return True
diff --git a/apps/cic-eth/tests/fixtures_config.py b/apps/cic-eth/tests/fixtures_config.py
new file mode 100644
index 00000000..135df0fd
--- /dev/null
+++ b/apps/cic-eth/tests/fixtures_config.py
@@ -0,0 +1,27 @@
+# standard imports
+import os
+import logging
+
+# third-party imports
+import pytest
+import confini
+
+script_dir = os.path.dirname(os.path.realpath(__file__))
+root_dir = os.path.dirname(script_dir)
+logg = logging.getLogger(__file__)
+
+
+@pytest.fixture(scope='session')
+def load_config():
+ config_dir = os.path.join(root_dir, 'config/test')
+ conf = confini.Config(config_dir, 'CICTEST')
+ conf.process()
+ logg.debug('config {}'.format(conf))
+ return conf
+
+
+@pytest.fixture(scope='session')
+def config(
+ load_config
+ ):
+ return load_config
diff --git a/apps/cic-eth/tests/fixtures_database.py b/apps/cic-eth/tests/fixtures_database.py
new file mode 100644
index 00000000..b4fddd8c
--- /dev/null
+++ b/apps/cic-eth/tests/fixtures_database.py
@@ -0,0 +1,58 @@
+# standard imports
+import os
+import logging
+
+# third-party imports
+import pytest
+import alembic
+from alembic.config import Config as AlembicConfig
+
+# local imports
+from cic_eth.db import SessionBase
+from cic_eth.db import dsn_from_config
+
+logg = logging.getLogger(__file__)
+
+
+@pytest.fixture(scope='session')
+def database_engine(
+ load_config,
+ ):
+ if load_config.get('DATABASE_ENGINE') == 'sqlite':
+ try:
+ os.unlink(load_config.get('DATABASE_NAME'))
+ except FileNotFoundError:
+ pass
+ SessionBase.transactional = False
+ SessionBase.poolable = False
+ dsn = dsn_from_config(load_config)
+ #SessionBase.connect(dsn, True)
+ SessionBase.connect(dsn, load_config.get('DATABASE_DEBUG') != None)
+ return dsn
+
+
+@pytest.fixture(scope='function')
+def init_database(
+ load_config,
+ database_engine,
+ ):
+
+ rootdir = os.path.dirname(os.path.dirname(__file__))
+ dbdir = os.path.join(rootdir, 'cic_eth', 'db')
+ migrationsdir = os.path.join(dbdir, 'migrations', load_config.get('DATABASE_ENGINE'))
+ if not os.path.isdir(migrationsdir):
+ migrationsdir = os.path.join(dbdir, 'migrations', 'default')
+ logg.info('using migrations directory {}'.format(migrationsdir))
+
+ session = SessionBase.create_session()
+
+ ac = AlembicConfig(os.path.join(migrationsdir, 'alembic.ini'))
+ ac.set_main_option('sqlalchemy.url', database_engine)
+ ac.set_main_option('script_location', migrationsdir)
+
+ alembic.command.downgrade(ac, 'base')
+ alembic.command.upgrade(ac, 'head')
+
+ yield session
+ session.commit()
+ session.close()
diff --git a/apps/cic-eth/tests/fixtures_faucet.py b/apps/cic-eth/tests/fixtures_faucet.py
new file mode 100644
index 00000000..3bfa6972
--- /dev/null
+++ b/apps/cic-eth/tests/fixtures_faucet.py
@@ -0,0 +1,74 @@
+# third-party imports
+import pytest
+from cic_registry.pytest import *
+from erc20_single_shot_faucet import Faucet
+from cic_registry import zero_address
+
+
+@pytest.fixture(scope='session')
+def faucet_amount():
+ return 50
+
+
+@pytest.fixture(scope='session')
+def faucet(
+ faucet_amount,
+ config,
+ default_chain_spec,
+ cic_registry,
+ bancor_tokens,
+ w3_account_roles,
+ w3_account_token_owners,
+ solidity_abis,
+ w3,
+ #accounts_registry,
+ ):
+
+
+ abi = Faucet.abi('storage')
+ bytecode = Faucet.bytecode('storage')
+
+ cs = w3.eth.contract(abi=abi, bytecode=bytecode)
+ tx_hash = cs.constructor().transact({'from': w3_account_roles['eth_account_faucet_owner']})
+ rcpt = w3.eth.getTransactionReceipt(tx_hash)
+ cs_address = rcpt.contractAddress
+
+ abi = Faucet.abi()
+ bytecode = Faucet.bytecode()
+ cf = w3.eth.contract(abi=abi, bytecode=bytecode)
+
+ tx_hash = cf.constructor(
+ [
+ w3_account_roles['eth_account_faucet_owner']
+ ],
+ bancor_tokens[0],
+ cs_address,
+ zero_address,
+ #accounts_registry,
+ ).transact({
+ 'from': w3_account_roles['eth_account_faucet_owner']
+ }
+ )
+
+ rcpt = w3.eth.getTransactionReceipt(tx_hash)
+ cf_address = rcpt.contractAddress
+
+ c = w3.eth.contract(abi=abi, address=cf_address)
+ c.functions.setAmount(50).transact({
+ 'from': w3_account_roles['eth_account_faucet_owner']
+ }
+ )
+
+ logg.debug('foo {} bar {}'.format(cf_address, w3_account_roles))
+
+ # fund the faucet with token balance
+ token = w3.eth.contract(abi=solidity_abis['ERC20'], address=bancor_tokens[0])
+ token_symbol = token.functions.symbol().call()
+ tx_hash = token.functions.transfer(cf_address, 100000).transact({
+ 'from': w3_account_token_owners[token_symbol],
+ })
+
+ CICRegistry.add_contract(default_chain_spec, c, 'Faucet')
+
+ return cf_address
+
diff --git a/apps/cic-eth/tests/fixtures_keystore.py b/apps/cic-eth/tests/fixtures_keystore.py
new file mode 100644
index 00000000..c8864cb8
--- /dev/null
+++ b/apps/cic-eth/tests/fixtures_keystore.py
@@ -0,0 +1,52 @@
+# standard imports
+import os
+import json
+import logging
+
+# third-party imports
+import pytest
+from cic_eth.eth.rpc import RpcClient
+from crypto_dev_signer.keystore import ReferenceKeystore
+#from crypto_dev_signer.eth.web3ext import Web3 as Web3ext
+
+logg = logging.getLogger(__file__)
+
+
+# TODO: need mock for deterministic signatures
+# depends on mock blockchain (ganache) where private key is passed directly to this module
+@pytest.fixture(scope='session')
+def init_mock_keystore(
+ ):
+ raise NotImplementedError
+
+
+@pytest.fixture(scope='session')
+def init_keystore(
+ load_config,
+ database_engine,
+ ):
+ #symkey_hex = os.environ.get('CIC_SIGNER_SECRET')
+ symkey_hex = load_config.get('SIGNER_SECRET')
+ symkey = bytes.fromhex(symkey_hex)
+ opt = {
+ 'symmetric_key': symkey,
+ }
+ k = ReferenceKeystore(database_engine, **opt)
+ k.db_session.execute('DELETE from ethereum')
+ k.db_session.commit()
+ keys_file = load_config.get('SIGNER_DEV_KEYS_PATH')
+ addresses = []
+ if keys_file:
+ logg.debug('loading keys from {}'.format(keys_file))
+ f = open(keys_file, 'r')
+ j = json.load(f)
+ f.close()
+ signer_password = load_config.get('SIGNER_PASSWORD')
+ for pk in j['private']:
+ address_hex = k.import_raw_key(bytes.fromhex(pk[2:]), signer_password)
+ addresses.append(address_hex)
+
+ RpcClient.set_provider_address(addresses[0])
+ return addresses
+
+
diff --git a/apps/cic-eth/tests/fixtures_registry.py b/apps/cic-eth/tests/fixtures_registry.py
new file mode 100644
index 00000000..8f3067e4
--- /dev/null
+++ b/apps/cic-eth/tests/fixtures_registry.py
@@ -0,0 +1,10 @@
+# third-party imports
+import pytest
+import os
+import json
+
+# local imports
+from cic_registry import CICRegistry
+from cic_registry.contract import Contract
+from cic_registry.error import ChainExistsError
+
diff --git a/apps/cic-eth/tests/fixtures_token.py b/apps/cic-eth/tests/fixtures_token.py
new file mode 100644
index 00000000..b4aa426a
--- /dev/null
+++ b/apps/cic-eth/tests/fixtures_token.py
@@ -0,0 +1,27 @@
+# third-party imports
+import pytest
+from cic_registry import CICRegistry
+
+
+@pytest.fixture(scope='session')
+def token_registry(
+ default_chain_spec,
+ cic_registry,
+ solidity_abis,
+ evm_bytecodes,
+ w3,
+ ):
+
+ abi = solidity_abis['TokenRegistry']
+ bytecode = evm_bytecodes['TokenRegistry']
+
+ c = w3.eth.contract(abi=abi, bytecode=bytecode)
+ tx_hash = c.constructor().transact({'from': w3.eth.accounts[0]})
+ rcpt = w3.eth.getTransactionReceipt(tx_hash)
+ address = rcpt.contractAddress
+
+ c = w3.eth.contract(abi=abi, address=address)
+
+ CICRegistry.add_contract(default_chain_spec, c, 'TokenRegistry')
+
+ return address
diff --git a/apps/cic-eth/tests/fixtures_transferapproval.py b/apps/cic-eth/tests/fixtures_transferapproval.py
new file mode 100644
index 00000000..5c93cfe8
--- /dev/null
+++ b/apps/cic-eth/tests/fixtures_transferapproval.py
@@ -0,0 +1,30 @@
+# third-party imports
+import pytest
+from cic_registry.pytest import *
+from erc20_approval_escrow import TransferApproval
+
+
+@pytest.fixture(scope='session')
+def transfer_approval(
+ config,
+ default_chain_spec,
+ default_chain_registry,
+ bancor_tokens,
+ w3_account_roles,
+ cic_registry,
+ w3,
+ ):
+
+ abi = TransferApproval.abi()
+ bytecode = TransferApproval.bytecode()
+
+ c = w3.eth.contract(abi=abi, bytecode=bytecode)
+ approvers = [w3_account_roles['eth_account_approval_owner']]
+ tx_hash = c.constructor(approvers).transact({'from': w3_account_roles['eth_account_approval_owner']})
+ rcpt = w3.eth.getTransactionReceipt(tx_hash)
+
+ c = w3.eth.contract(abi=abi, address=rcpt.contractAddress)
+
+ CICRegistry.add_contract(default_chain_spec, c, 'TransferApproval')
+
+ return rcpt.contractAddress
diff --git a/apps/cic-eth/tests/fixtures_web3.py b/apps/cic-eth/tests/fixtures_web3.py
new file mode 100644
index 00000000..44999ff9
--- /dev/null
+++ b/apps/cic-eth/tests/fixtures_web3.py
@@ -0,0 +1,203 @@
+# standard imports
+import os
+import logging
+
+# third-party imports
+import hexbytes
+import pytest
+import web3
+import eth_tester
+from crypto_dev_signer.eth.transaction import EIP155Transaction
+from crypto_dev_signer.eth.signer.defaultsigner import ReferenceSigner as EIP155Signer
+from eth_keys import KeyAPI
+
+# local imports
+from cic_eth.eth import RpcClient
+from cic_eth.eth.rpc import GasOracle
+from cic_eth.db.models.role import AccountRole
+
+#logg = logging.getLogger(__name__)
+logg = logging.getLogger()
+
+
+@pytest.fixture(scope='session')
+def init_w3_nokey(
+ ):
+ provider = 'http://localhost:8545'
+ return web3.Web3(provider)
+
+
+class ProviderWalletExtension:
+
+ def __init__(self, provider, gas_price=1000000):
+ self.provider = provider
+ self.signer = EIP155Signer(provider)
+ self.default_gas_price = gas_price
+
+
+ def get(self, address, password=None):
+ return self.provider.get(address, password)
+
+
+ def new_account(self, password=None):
+ keys = KeyAPI()
+ pk = os.urandom(32)
+ account = self.provider.add_account(pk.hex())
+ self.provider.accounts[account] = keys.PrivateKey(pk)
+ return account
+
+
+ def sign_transaction(self, tx):
+ tx['chainId'] = int(tx['chainId'])
+ logg.debug('signing {}'.format(tx))
+ signer_tx = EIP155Transaction(tx, tx['nonce'], tx['chainId'])
+ tx_signed = self.signer.signTransaction(signer_tx)
+ tx_signed_dict = signer_tx.serialize()
+ tx_signed_dict['raw'] = '0x' + signer_tx.rlp_serialize().hex()
+ return tx_signed_dict
+
+
+ def sign(self, address, text=None, bytes=None):
+ logg.debug('sign message {} {}'.format(address[2:], text))
+ return self.signer.signEthereumMessage(address[2:], text)
+
+
+ def send_raw_transaction(self, rlp_tx_hex):
+ raw_tx = self.provider.backend.send_raw_transaction(bytes.fromhex(rlp_tx_hex[2:]))
+ return raw_tx
+
+
+ def gas_price(self):
+ return self.default_gas_price
+
+
+@pytest.fixture(scope='session')
+def init_wallet_extension(
+ init_eth_tester,
+ eth_provider,
+ ):
+
+ x = ProviderWalletExtension(init_eth_tester)
+
+ def _rpcclient_web3_constructor():
+ w3 = web3.Web3(eth_provider)
+ setattr(w3.eth, 'personal', x)
+ setattr(w3.eth, 'sign_transaction', x.sign_transaction)
+ setattr(w3.eth, 'send_raw_transaction', x.send_raw_transaction)
+ setattr(w3.eth, 'sign', x.sign)
+ setattr(w3.eth, 'gas_price', x.gas_price)
+ return (init_eth_tester, w3)
+
+ RpcClient.set_constructor(_rpcclient_web3_constructor)
+ init_eth_tester.signer = EIP155Signer(x)
+ return x
+
+
+@pytest.fixture(scope='session')
+def init_w3_conn(
+ default_chain_spec,
+ init_eth_tester,
+ init_wallet_extension,
+ ):
+
+ c = RpcClient(default_chain_spec)
+ x = ProviderWalletExtension(init_eth_tester)
+
+ # a hack to make available missing rpc calls we need
+ setattr(c.w3.eth, 'personal', x)
+ setattr(c.w3.eth, 'sign_transaction', x.sign_transaction)
+ setattr(c.w3.eth, 'send_raw_transaction', x.send_raw_transaction)
+ setattr(c.w3.eth, 'sign', x.sign)
+ return c.w3
+
+
+@pytest.fixture(scope='function')
+def init_w3(
+ init_eth_tester,
+ init_eth_account_roles,
+ init_w3_conn,
+ ):
+
+ yield init_w3_conn
+ logg.debug('mining om nom nom... {}'.format(init_eth_tester.mine_block()))
+
+
+@pytest.fixture(scope='function')
+def init_eth_account_roles(
+ init_database,
+ w3_account_roles,
+ ):
+
+ role = AccountRole.set('GAS_GIFTER', w3_account_roles.get('eth_account_gas_provider'))
+ init_database.add(role)
+ init_database.commit()
+ return w3_account_roles
+
+
+@pytest.fixture(scope='function')
+def init_rpc(
+ default_chain_spec,
+ init_eth_account_roles,
+ init_eth_tester,
+ init_wallet_extension,
+ ):
+
+ c = RpcClient(default_chain_spec)
+ x = ProviderWalletExtension(init_eth_tester)
+
+ # a hack to make available missing rpc calls we need
+ setattr(c.w3.eth, 'personal', x)
+ setattr(c.w3.eth, 'sign_transaction', x.sign_transaction)
+ setattr(c.w3.eth, 'send_raw_transaction', x.send_raw_transaction)
+ setattr(c.w3.eth, 'sign', x.sign)
+ yield c
+ logg.debug('mining om nom nom... {}'.format(init_eth_tester.mine_block()))
+
+
+
+@pytest.fixture(scope='session')
+def w3_account_roles(
+ config,
+ w3,
+ ):
+
+ role_ids = [
+ 'eth_account_bancor_deployer',
+ 'eth_account_gas_provider',
+ 'eth_account_reserve_owner',
+ 'eth_account_reserve_minter',
+ 'eth_account_accounts_index_owner',
+ 'eth_account_accounts_index_writer',
+ 'eth_account_sarafu_owner',
+ 'eth_account_sarafu_gifter',
+ 'eth_account_approval_owner',
+ 'eth_account_faucet_owner',
+ ]
+ roles = {}
+
+ i = 0
+ for r in role_ids:
+ a = w3.eth.accounts[i]
+ try:
+ a = config.get(r.upper())
+ except KeyError:
+ pass
+ roles[r] = a
+ i += 1
+
+ return roles
+
+@pytest.fixture(scope='session')
+def w3_account_token_owners(
+ tokens_to_deploy,
+ w3,
+ ):
+
+ token_owners = {}
+
+ i = 1
+ for t in tokens_to_deploy:
+ token_owners[t[2]] = w3.eth.accounts[i]
+ i += 1
+
+ return token_owners
diff --git a/apps/cic-eth/tests/functional/test_admin.py b/apps/cic-eth/tests/functional/test_admin.py
new file mode 100644
index 00000000..9d653814
--- /dev/null
+++ b/apps/cic-eth/tests/functional/test_admin.py
@@ -0,0 +1,215 @@
+# standard imports
+import os
+import logging
+
+# third-party imports
+import celery
+import pytest
+import web3
+
+# local imports
+from cic_eth.api import AdminApi
+from cic_eth.db.models.role import AccountRole
+from cic_eth.db.enum import StatusEnum
+from cic_eth.error import InitializationError
+from cic_eth.eth.task import sign_and_register_tx
+from cic_eth.eth.tx import cache_gas_refill_data
+from cic_eth.eth.util import unpack_signed_raw_tx
+from cic_eth.eth.rpc import RpcClient
+from cic_eth.eth.task import sign_tx
+from cic_eth.eth.tx import otx_cache_parse_tx
+from cic_eth.queue.tx import create as queue_create
+from cic_eth.queue.tx import get_tx
+
+logg = logging.getLogger()
+
+
+def test_resend_inplace(
+ default_chain_spec,
+ init_database,
+ init_w3,
+ celery_session_worker,
+ ):
+
+ chain_str = str(default_chain_spec)
+ c = RpcClient(default_chain_spec)
+
+ sigs = []
+ s = celery.signature(
+ 'cic_eth.eth.tx.refill_gas',
+ [
+ init_w3.eth.accounts[0],
+ chain_str,
+ ],
+ queue=None,
+ )
+ t = s.apply_async()
+ tx_raw = t.get()
+ assert t.successful()
+
+ tx_dict = unpack_signed_raw_tx(bytes.fromhex(tx_raw[2:]), default_chain_spec.chain_id())
+ gas_price_before = tx_dict['gasPrice']
+
+ s = celery.signature(
+ 'cic_eth.admin.ctrl.lock_send',
+ [
+ chain_str,
+ init_w3.eth.accounts[0],
+ ],
+ queue=None,
+ )
+ t = s.apply_async()
+ t.get()
+ assert t.successful()
+
+ api = AdminApi(c, queue=None)
+ t = api.resend(tx_dict['hash'], chain_str, unlock=True)
+ tx_hash_new_hex = t.get()
+ assert t.successful()
+
+ tx_raw_new = get_tx(tx_hash_new_hex)
+ logg.debug('get {}'.format(tx_raw_new))
+ tx_dict_new = unpack_signed_raw_tx(bytes.fromhex(tx_raw_new['signed_tx'][2:]), default_chain_spec.chain_id())
+ assert tx_hash_new_hex != tx_dict['hash']
+ assert tx_dict_new['gasPrice'] > gas_price_before
+
+ tx_dict_after = get_tx(tx_dict['hash'])
+ assert tx_dict_after['status'] == StatusEnum.OVERRIDDEN
+
+
+def test_check_fix_nonce(
+ default_chain_spec,
+ init_database,
+ init_eth_account_roles,
+ init_w3,
+ eth_empty_accounts,
+ celery_session_worker,
+ ):
+
+ chain_str = str(default_chain_spec)
+
+ sigs = []
+ for i in range(5):
+ s = celery.signature(
+ 'cic_eth.eth.tx.refill_gas',
+ [
+ eth_empty_accounts[i],
+ chain_str,
+ ],
+ queue=None,
+ )
+ sigs.append(s)
+
+ t = celery.group(sigs)()
+ txs = t.get()
+ assert t.successful()
+
+ tx_hash = web3.Web3.keccak(hexstr=txs[2])
+ c = RpcClient(default_chain_spec)
+ api = AdminApi(c, queue=None)
+ address = init_eth_account_roles['eth_account_gas_provider']
+ nonce_spec = api.check_nonce(address)
+ assert nonce_spec['nonce']['network'] == 0
+ assert nonce_spec['nonce']['queue'] == 4
+ assert nonce_spec['nonce']['blocking'] == None
+
+ s_set = celery.signature(
+ 'cic_eth.queue.tx.set_rejected',
+ [
+ tx_hash.hex(),
+ ],
+ queue=None,
+ )
+ t = s_set.apply_async()
+ t.get()
+ t.collect()
+ assert t.successful()
+
+
+ nonce_spec = api.check_nonce(address)
+ assert nonce_spec['nonce']['blocking'] == 2
+ assert nonce_spec['tx']['blocking'] == tx_hash.hex()
+
+ t = api.fix_nonce(address, nonce_spec['nonce']['blocking'])
+ t.get()
+ t.collect()
+ assert t.successful()
+
+ for tx in txs[3:]:
+ tx_hash = web3.Web3.keccak(hexstr=tx)
+ tx_dict = get_tx(tx_hash.hex())
+ assert tx_dict['status'] == StatusEnum.OVERRIDDEN
+
+
+def test_tag_account(
+ init_database,
+ eth_empty_accounts,
+ init_rpc,
+ ):
+
+ api = AdminApi(init_rpc)
+
+ api.tag_account('foo', eth_empty_accounts[0])
+ api.tag_account('bar', eth_empty_accounts[1])
+ api.tag_account('bar', eth_empty_accounts[2])
+
+ assert AccountRole.get_address('foo') == eth_empty_accounts[0]
+ assert AccountRole.get_address('bar') == eth_empty_accounts[2]
+
+
+def test_ready(
+ init_database,
+ eth_empty_accounts,
+ init_rpc,
+ w3,
+ ):
+
+ api = AdminApi(init_rpc)
+
+ with pytest.raises(InitializationError):
+ api.ready()
+
+ bogus_account = os.urandom(20)
+ bogus_account_hex = '0x' + bogus_account.hex()
+
+ api.tag_account('ETH_GAS_PROVIDER_ADDRESS', web3.Web3.toChecksumAddress(bogus_account_hex))
+ with pytest.raises(KeyError):
+ api.ready()
+
+ api.tag_account('ETH_GAS_PROVIDER_ADDRESS', eth_empty_accounts[0])
+ api.ready()
+
+
+def test_tx(
+ default_chain_spec,
+ cic_registry,
+ init_database,
+ init_rpc,
+ init_w3,
+ celery_session_worker,
+ ):
+
+ tx = {
+ 'from': init_w3.eth.accounts[0],
+ 'to': init_w3.eth.accounts[1],
+ 'nonce': 42,
+ 'gas': 21000,
+ 'gasPrice': 1000000,
+ 'value': 128,
+ 'chainId': default_chain_spec.chain_id(),
+ 'data': '',
+ }
+
+ (tx_hash_hex, tx_signed_raw_hex) = sign_tx(tx, str(default_chain_spec))
+ queue_create(
+ tx['nonce'],
+ tx['from'],
+ tx_hash_hex,
+ tx_signed_raw_hex,
+ str(default_chain_spec),
+ )
+ tx_recovered = unpack_signed_raw_tx(bytes.fromhex(tx_signed_raw_hex[2:]), default_chain_spec.chain_id())
+ cache_gas_refill_data(tx_hash_hex, tx_recovered)
+
+ api = AdminApi(init_rpc, queue=None)
+ tx = api.tx(default_chain_spec, tx_hash=tx_hash_hex)
diff --git a/apps/cic-eth/tests/functional/test_app.py b/apps/cic-eth/tests/functional/test_app.py
new file mode 100644
index 00000000..29426ea5
--- /dev/null
+++ b/apps/cic-eth/tests/functional/test_app.py
@@ -0,0 +1,162 @@
+# standard imports
+import os
+import logging
+import time
+
+# third-party imports
+import pytest
+import celery
+from cic_registry import CICRegistry
+
+# platform imports
+from cic_eth.api import Api
+from cic_eth.eth.factory import TxFactory
+
+logg = logging.getLogger(__name__)
+
+def test_account_api(
+ default_chain_spec,
+ init_w3,
+ init_database,
+ init_eth_account_roles,
+ celery_session_worker,
+ ):
+ api = Api(str(default_chain_spec), callback_param='accounts', callback_task='cic_eth.callbacks.noop.noop', queue=None)
+ t = api.create_account('', register=False)
+ t.get()
+ for r in t.collect():
+ print(r)
+ assert t.successful()
+
+
+def test_balance_api(
+ default_chain_spec,
+ default_chain_registry,
+ init_w3,
+ cic_registry,
+ init_database,
+ bancor_tokens,
+ bancor_registry,
+ celery_session_worker,
+ ):
+
+ token = CICRegistry.get_address(default_chain_spec, bancor_tokens[0])
+
+ api = Api(str(default_chain_spec), callback_param='balance', callback_task='cic_eth.callbacks.noop.noop', queue=None)
+ t = api.balance(init_w3.eth.accounts[2], token.symbol())
+ t.get()
+ for r in t.collect():
+ print(r)
+ assert t.successful()
+
+
+def test_transfer_api(
+ default_chain_spec,
+ init_w3,
+ cic_registry,
+ init_database,
+ bancor_registry,
+ bancor_tokens,
+ celery_session_worker,
+ ):
+
+ token = CICRegistry.get_address(default_chain_spec, bancor_tokens[0])
+
+ api = Api(str(default_chain_spec), callback_param='transfer', callback_task='cic_eth.callbacks.noop.noop', queue=None)
+ t = api.transfer(init_w3.eth.accounts[2], init_w3.eth.accounts[4], 111, token.symbol())
+ t.get()
+ for r in t.collect():
+ print(r)
+ assert t.successful()
+
+
+def test_transfer_approval_api(
+ default_chain_spec,
+ init_w3,
+ cic_registry,
+ init_database,
+ bancor_registry,
+ bancor_tokens,
+ transfer_approval,
+ celery_session_worker,
+ ):
+
+ token = CICRegistry.get_address(default_chain_spec, bancor_tokens[0])
+ approval_contract = CICRegistry.get_contract(default_chain_spec, 'TransferApproval')
+
+ api = Api(str(default_chain_spec), callback_param='transfer_request', callback_task='cic_eth.callbacks.noop.noop', queue=None)
+ t = api.transfer_request(init_w3.eth.accounts[2], init_w3.eth.accounts[4], approval_contract.address(), 111, token.symbol())
+ t.get()
+ #for r in t.collect():
+ # print(r)
+ assert t.successful()
+
+
+def test_convert_api(
+ default_chain_spec,
+ init_w3,
+ cic_registry,
+ init_database,
+ bancor_registry,
+ bancor_tokens,
+ celery_session_worker,
+ ):
+
+ token_alice = CICRegistry.get_address(default_chain_spec, bancor_tokens[0])
+ token_bob = CICRegistry.get_address(default_chain_spec, bancor_tokens[1])
+
+ api = Api(str(default_chain_spec), callback_param='convert', callback_task='cic_eth.callbacks.noop.noop', queue=None)
+ t = api.convert(init_w3.eth.accounts[2], 110, 100, token_alice.symbol(), token_bob.symbol())
+ for r in t.collect():
+ print(r)
+ assert t.successful()
+
+
+def test_convert_transfer_api(
+ default_chain_spec,
+ init_w3,
+ cic_registry,
+ init_database,
+ bancor_registry,
+ bancor_tokens,
+ celery_session_worker,
+ ):
+
+ token_alice = CICRegistry.get_address(default_chain_spec, bancor_tokens[0])
+ token_bob = CICRegistry.get_address(default_chain_spec, bancor_tokens[1])
+
+ api = Api(str(default_chain_spec), callback_param='convert_transfer', callback_task='cic_eth.callbacks.noop.noop', queue=None)
+ t = api.convert_transfer(init_w3.eth.accounts[2], init_w3.eth.accounts[4], 110, 100, token_alice.symbol(), token_bob.symbol())
+ t.get()
+ for r in t.collect():
+ print(r)
+ assert t.successful()
+
+
+def test_refill_gas(
+ default_chain_spec,
+ cic_registry,
+ init_database,
+ init_w3,
+ celery_session_worker,
+ eth_empty_accounts,
+ ):
+
+ api = Api(str(default_chain_spec), callback_param='convert_transfer', callback_task='cic_eth.callbacks.noop.noop', queue=None)
+ t = api.refill_gas(eth_empty_accounts[0])
+ t.get()
+ for r in t.collect():
+ print(r)
+ assert t.successful()
+
+
+def test_ping(
+ default_chain_spec,
+ celery_session_worker,
+ ):
+ api = Api(str(default_chain_spec), callback_param='ping', callback_task='cic_eth.callbacks.noop.noop', queue=None)
+ t = api.ping('pong')
+ t.get()
+ for r in t.collect():
+ print(r)
+ assert t.successful()
diff --git a/apps/cic-eth/tests/tasks/test_account.py b/apps/cic-eth/tests/tasks/test_account.py
new file mode 100644
index 00000000..b98436b0
--- /dev/null
+++ b/apps/cic-eth/tests/tasks/test_account.py
@@ -0,0 +1,128 @@
+# standard imports
+import os
+import logging
+import time
+
+# third-party imports
+import pytest
+import web3
+import celery
+
+# local imports
+from cic_eth.error import OutOfGasError
+from cic_eth.db.models.otx import Otx
+from cic_eth.db.models.base import SessionBase
+from cic_eth.db.enum import StatusEnum
+from cic_eth.db.enum import StatusEnum
+from cic_eth.db.models.nonce import Nonce
+from cic_eth.db.models.role import AccountRole
+from cic_eth.eth.account import AccountTxFactory
+
+logg = logging.getLogger() #__name__)
+
+
+def test_create_account(
+ default_chain_spec,
+ init_w3,
+ init_database,
+ celery_session_worker,
+ ):
+
+ s = celery.signature(
+ 'cic_eth.eth.account.create',
+ [
+ 'foo',
+ str(default_chain_spec),
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+ logg.debug('got account {}'.format(r))
+
+ session = SessionBase.create_session()
+ q = session.query(Nonce).filter(Nonce.address_hex==r)
+ o = q.first()
+ logg.debug('oooo s {}'.format(o))
+ session.close()
+ assert o != None
+ assert o.nonce == 0
+
+ s = celery.signature(
+ 'cic_eth.eth.account.have',
+ [
+ r,
+ str(default_chain_spec),
+ ],
+ )
+ t = s.apply_async()
+ assert r == t.get()
+
+
+def test_register_account(
+ default_chain_spec,
+ accounts_registry,
+ init_database,
+ init_eth_tester,
+ init_w3,
+ cic_registry,
+ celery_session_worker,
+ eth_empty_accounts,
+ ):
+
+ logg.debug('chainspec {}'.format(str(default_chain_spec)))
+
+ s = celery.signature(
+ 'cic_eth.eth.account.register',
+ [
+ eth_empty_accounts[0],
+ str(default_chain_spec),
+ init_w3.eth.accounts[0],
+ ],
+ )
+ t = s.apply_async()
+ address = t.get()
+ r = t.collect()
+ t.successful()
+
+ session = SessionBase.create_session()
+ o = session.query(Otx).first()
+ tx_signed_hex = o.signed_tx
+ session.close()
+
+ s_send = celery.signature(
+ 'cic_eth.eth.tx.send',
+ [
+ [tx_signed_hex],
+ str(default_chain_spec),
+ ],
+ )
+ t = s_send.apply_async()
+ address = t.get()
+ r = t.collect()
+ t.successful()
+
+ init_eth_tester.mine_block()
+
+ assert accounts_registry.have(eth_empty_accounts[0])
+
+
+def test_role_task(
+ init_database,
+ celery_session_worker,
+ default_chain_spec,
+ ):
+
+ address = '0x' + os.urandom(20).hex()
+ role = AccountRole.set('foo', address)
+ init_database.add(role)
+ init_database.commit()
+ s = celery.signature(
+ 'cic_eth.eth.account.role',
+ [
+ address,
+ str(default_chain_spec),
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+ assert r == 'foo'
diff --git a/apps/cic-eth/tests/tasks/test_convert.py b/apps/cic-eth/tests/tasks/test_convert.py
new file mode 100644
index 00000000..46857b69
--- /dev/null
+++ b/apps/cic-eth/tests/tasks/test_convert.py
@@ -0,0 +1,45 @@
+import logging
+import os
+
+import celery
+
+from cic_eth.db import TxConvertTransfer
+from cic_eth.eth.bancor import BancorTxFactory
+
+logg = logging.getLogger()
+
+
+def test_transfer_after_convert(
+ init_w3,
+ init_database,
+ cic_registry,
+ bancor_tokens,
+ bancor_registry,
+ default_chain_spec,
+ celery_session_worker,
+ ):
+
+ tx_hash = os.urandom(32).hex()
+ txct = TxConvertTransfer(tx_hash, init_w3.eth.accounts[1], default_chain_spec)
+ init_database.add(txct)
+ init_database.commit()
+
+ s = celery.signature(
+ 'cic_eth.eth.bancor.transfer_converted',
+ [
+ [
+ {
+ 'address': bancor_tokens[0],
+ },
+ ],
+ init_w3.eth.accounts[0],
+ init_w3.eth.accounts[1],
+ 1024,
+ tx_hash,
+ str(default_chain_spec),
+ ],
+ )
+ t = s.apply_async()
+ t.get()
+ t.collect()
+ assert t.successful()
diff --git a/apps/cic-eth/tests/tasks/test_faucet.py b/apps/cic-eth/tests/tasks/test_faucet.py
new file mode 100644
index 00000000..b6575ef4
--- /dev/null
+++ b/apps/cic-eth/tests/tasks/test_faucet.py
@@ -0,0 +1,66 @@
+# standard imports
+import os
+import json
+import logging
+
+# third-party imports
+import celery
+
+# local imports
+from cic_eth.eth.account import unpack_gift
+from cic_eth.eth.factory import TxFactory
+from cic_eth.eth.util import unpack_signed_raw_tx
+
+logg = logging.getLogger()
+
+script_dir = os.path.dirname(__file__)
+
+
+def test_faucet(
+ default_chain_spec,
+ faucet_amount,
+ faucet,
+ eth_empty_accounts,
+ bancor_tokens,
+ w3_account_roles,
+ w3_account_token_owners,
+ init_w3,
+ solidity_abis,
+ init_eth_tester,
+ cic_registry,
+ celery_session_worker,
+ init_database,
+ ):
+
+ s = celery.signature(
+ 'cic_eth.eth.account.gift',
+ [
+ init_w3.eth.accounts[7],
+ str(default_chain_spec),
+ ],
+ )
+ s_send = celery.signature(
+ 'cic_eth.eth.tx.send',
+ [
+ str(default_chain_spec),
+ ],
+ )
+ s.link(s_send)
+ t = s.apply_async()
+ signed_tx = t.get()
+ for r in t.collect():
+ logg.debug('result {}'.format(r))
+
+ assert t.successful()
+
+ tx = unpack_signed_raw_tx(bytes.fromhex(signed_tx[0][2:]), default_chain_spec.chain_id())
+ giveto = unpack_gift(tx['data'])
+ assert giveto['to'] == init_w3.eth.accounts[7]
+
+ init_eth_tester.mine_block()
+
+ token = init_w3.eth.contract(abi=solidity_abis['ERC20'], address=bancor_tokens[0])
+
+ balance = token.functions.balanceOf(init_w3.eth.accounts[7]).call()
+
+ assert balance == faucet_amount
diff --git a/apps/cic-eth/tests/tasks/test_gas_tasks.py b/apps/cic-eth/tests/tasks/test_gas_tasks.py
new file mode 100644
index 00000000..c3fa07c7
--- /dev/null
+++ b/apps/cic-eth/tests/tasks/test_gas_tasks.py
@@ -0,0 +1,246 @@
+# standard imports
+import logging
+import time
+
+# third-party imports
+import pytest
+import celery
+from web3.exceptions import ValidationError
+
+# local imports
+from cic_eth.db.enum import StatusEnum
+from cic_eth.db.models.otx import Otx
+from cic_eth.db.models.tx import TxCache
+from cic_eth.db.models.base import SessionBase
+from cic_eth.eth.task import sign_and_register_tx
+from cic_eth.eth.task import sign_tx
+from cic_eth.eth.token import TokenTxFactory
+from cic_eth.eth.token import TxFactory
+from cic_eth.eth.token import cache_transfer_data
+from cic_eth.eth.rpc import RpcClient
+from cic_eth.queue.tx import create as queue_create
+from cic_eth.error import OutOfGasError
+from cic_eth.db.models.role import AccountRole
+from cic_eth.error import AlreadyFillingGasError
+
+logg = logging.getLogger()
+
+
+def test_refill_gas(
+ default_chain_spec,
+ init_eth_tester,
+ init_rpc,
+ init_database,
+ cic_registry,
+ init_eth_account_roles,
+ celery_session_worker,
+ eth_empty_accounts,
+ ):
+
+ provider_address = AccountRole.get_address('GAS_GIFTER')
+ receiver_address = eth_empty_accounts[0]
+
+ c = init_rpc
+ refill_amount = c.refill_amount()
+
+ balance = init_rpc.w3.eth.getBalance(receiver_address)
+ s = celery.signature(
+ 'cic_eth.eth.tx.refill_gas',
+ [
+ receiver_address,
+ str(default_chain_spec),
+ ],
+ )
+
+ t = s.apply_async()
+ r = t.get()
+ t.collect()
+ assert t.successful()
+
+ s = celery.signature(
+ 'cic_eth.eth.tx.send',
+ [
+ [r],
+ str(default_chain_spec),
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+ t.collect()
+ assert t.successful()
+
+ init_eth_tester.mine_block()
+ balance_new = init_rpc.w3.eth.getBalance(receiver_address)
+ assert balance_new == (balance + refill_amount)
+
+ # Verify that entry is added in TxCache
+ session = SessionBase.create_session()
+ q = session.query(Otx)
+ q = q.join(TxCache)
+ q = q.filter(TxCache.recipient==receiver_address)
+ r = q.first()
+
+ assert r.status == StatusEnum.SENT
+
+
+def test_refill_deduplication(
+ default_chain_spec,
+ init_rpc,
+ init_database,
+ init_eth_account_roles,
+ cic_registry,
+ celery_session_worker,
+ eth_empty_accounts,
+ ):
+
+ provider_address = AccountRole.get_address('ETH_GAS_PROVIDER_ADDRESS')
+ receiver_address = eth_empty_accounts[0]
+
+ c = init_rpc
+ refill_amount = c.refill_amount()
+
+ s = celery.signature(
+ 'cic_eth.eth.tx.refill_gas',
+ [
+ receiver_address,
+ str(default_chain_spec),
+ ],
+ )
+
+ t = s.apply_async()
+ r = t.get()
+ for e in t.collect():
+ pass
+ assert t.successful()
+
+ s = celery.signature(
+ 'cic_eth.eth.tx.refill_gas',
+ [
+ receiver_address,
+ str(default_chain_spec),
+ ],
+ )
+
+ t = s.apply_async()
+ with pytest.raises(AlreadyFillingGasError):
+ t.get()
+
+
+def test_check_gas(
+ default_chain_spec,
+ init_eth_tester,
+ init_w3,
+ init_rpc,
+ eth_empty_accounts,
+ init_database,
+ cic_registry,
+ celery_session_worker,
+ bancor_registry,
+ bancor_tokens,
+ ):
+
+ provider_address = init_w3.eth.accounts[0]
+ gas_receiver_address = eth_empty_accounts[0]
+ token_receiver_address = init_w3.eth.accounts[1]
+
+ c = init_rpc
+ txf = TokenTxFactory(gas_receiver_address, c)
+ tx_transfer = txf.transfer(bancor_tokens[0], token_receiver_address, 42, default_chain_spec)
+
+ (tx_hash_hex, tx_signed_raw_hex) = sign_and_register_tx(tx_transfer, str(default_chain_spec), None)
+
+ gas_price = c.gas_price()
+ gas_limit = tx_transfer['gas']
+
+ s = celery.signature(
+ 'cic_eth.eth.tx.check_gas',
+ [
+ [tx_hash_hex],
+ str(default_chain_spec),
+ [],
+ gas_receiver_address,
+ gas_limit * gas_price,
+ ],
+ )
+ t = s.apply_async()
+ with pytest.raises(OutOfGasError):
+ r = t.get()
+ #assert len(r) == 0
+
+ time.sleep(1)
+ t.collect()
+
+ session = SessionBase.create_session()
+ q = session.query(Otx)
+ q = q.filter(Otx.tx_hash==tx_hash_hex)
+ r = q.first()
+ session.close()
+ assert r.status == StatusEnum.WAITFORGAS
+
+
+def test_resend_with_higher_gas(
+ default_chain_spec,
+ init_eth_tester,
+ init_w3,
+ init_rpc,
+ init_database,
+ cic_registry,
+ celery_session_worker,
+ bancor_registry,
+ bancor_tokens,
+ ):
+
+ c = init_rpc
+ txf = TokenTxFactory(init_w3.eth.accounts[0], c)
+
+ tx_transfer = txf.transfer(bancor_tokens[0], init_w3.eth.accounts[1], 1024, default_chain_spec)
+ logg.debug('txtransfer {}'.format(tx_transfer))
+ (tx_hash_hex, tx_signed_raw_hex) = sign_tx(tx_transfer, str(default_chain_spec))
+ logg.debug('signed raw {}'.format(tx_signed_raw_hex))
+ queue_create(
+ tx_transfer['nonce'],
+ tx_transfer['from'],
+ tx_hash_hex,
+ tx_signed_raw_hex,
+ str(default_chain_spec),
+ )
+ logg.debug('create {}'.format(tx_transfer['from']))
+ cache_transfer_data(
+ tx_hash_hex,
+ tx_transfer, #_signed_raw_hex,
+ )
+
+ s_resend = celery.signature(
+ 'cic_eth.eth.tx.resend_with_higher_gas',
+ [
+ tx_hash_hex,
+ str(default_chain_spec),
+ ],
+ )
+ t = s_resend.apply_async()
+
+ i = 0
+ for r in t.collect():
+ logg.debug('{} {}'.format(i, r[0].get()))
+ i += 1
+
+ assert t.successful()
+
+#
+#def test_resume(
+# default_chain_spec,
+# init_eth_tester,
+# w3,
+# w3_account_roles,
+# init_database,
+# bancor_tokens,
+# celery_session_worker,
+# eth_empty_accounts,
+# ):
+#
+# txf = TokenTxFactory()
+#
+# tx_transfer = txf.transfer(bancor_tokens[0], eth_empty_accounts[1], 1024)
+# (tx_hash_hex, tx_signed_raw_hex) = sign_and_register_tx(tx_transfer)
+#
+# resume_tx()
diff --git a/apps/cic-eth/tests/tasks/test_lock_tasks.py b/apps/cic-eth/tests/tasks/test_lock_tasks.py
new file mode 100644
index 00000000..cd077ea2
--- /dev/null
+++ b/apps/cic-eth/tests/tasks/test_lock_tasks.py
@@ -0,0 +1,355 @@
+# standard imports
+import os
+
+# third-party imports
+import celery
+import pytest
+
+# local imports
+from cic_eth.db.models.lock import Lock
+from cic_eth.db.models.otx import Otx
+from cic_eth.db.enum import LockEnum
+from cic_eth.error import LockedError
+
+
+@pytest.mark.parametrize(
+ 'task_postfix,flag_enum',
+ [
+ ('send', LockEnum.SEND),
+ ('queue', LockEnum.QUEUE),
+ ],
+ )
+def test_lock_task(
+ init_database,
+ celery_session_worker,
+ default_chain_spec,
+ task_postfix,
+ flag_enum,
+ ):
+
+ chain_str = str(default_chain_spec)
+ address = '0x' + os.urandom(20).hex()
+
+ s = celery.signature(
+ 'cic_eth.admin.ctrl.lock_{}'.format(task_postfix),
+ [
+ 'foo',
+ chain_str,
+ address,
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+ assert t.successful()
+ assert r == 'foo'
+
+ q = init_database.query(Lock)
+ q = q.filter(Lock.address==address)
+ lock = q.first()
+ assert lock != None
+ assert lock.flags == flag_enum
+
+ s = celery.signature(
+ 'cic_eth.admin.ctrl.unlock_{}'.format(task_postfix),
+ [
+ 'foo',
+ chain_str,
+ address,
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+ assert t.successful()
+ assert r == 'foo'
+
+ q = init_database.query(Lock)
+ q = q.filter(Lock.address==address)
+ lock = q.first()
+ assert lock == None
+
+
+def test_lock_check_task(
+ init_database,
+ celery_session_worker,
+ default_chain_spec,
+ ):
+
+ chain_str = str(default_chain_spec)
+ address = '0x' + os.urandom(20).hex()
+
+ s = celery.signature(
+ 'cic_eth.admin.ctrl.lock_send',
+ [
+ 'foo',
+ chain_str,
+ address,
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+
+ s = celery.signature(
+ 'cic_eth.admin.ctrl.lock_queue',
+ [
+ 'foo',
+ chain_str,
+ address,
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+
+ s = celery.signature(
+ 'cic_eth.admin.ctrl.check_lock',
+ [
+ 'foo',
+ chain_str,
+ LockEnum.SEND,
+ address,
+ ],
+ )
+ t = s.apply_async()
+
+ with pytest.raises(LockedError):
+ r = t.get()
+
+
+ s = celery.signature(
+ 'cic_eth.admin.ctrl.check_lock',
+ [
+ 'foo',
+ chain_str,
+ LockEnum.CREATE,
+ address,
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+ assert r == 'foo'
+
+
+def test_lock_arbitrary_task(
+ init_database,
+ celery_session_worker,
+ default_chain_spec,
+ ):
+
+ chain_str = str(default_chain_spec)
+ address = '0x' + os.urandom(20).hex()
+
+ s = celery.signature(
+ 'cic_eth.admin.ctrl.lock',
+ [
+ 'foo',
+ chain_str,
+ address,
+ LockEnum.SEND | LockEnum.QUEUE,
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+ assert r == 'foo'
+
+ s = celery.signature(
+ 'cic_eth.admin.ctrl.check_lock',
+ [
+ 'foo',
+ chain_str,
+ LockEnum.SEND | LockEnum.QUEUE,
+ address,
+ ],
+ )
+ t = s.apply_async()
+ with pytest.raises(LockedError):
+ r = t.get()
+ assert r == 'foo'
+
+ s = celery.signature(
+ 'cic_eth.admin.ctrl.unlock',
+ [
+ 'foo',
+ chain_str,
+ address,
+ LockEnum.SEND,
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+ assert r == 'foo'
+
+
+ s = celery.signature(
+ 'cic_eth.admin.ctrl.check_lock',
+ [
+ 'foo',
+ chain_str,
+ LockEnum.SEND,
+ address,
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+
+
+ s = celery.signature(
+ 'cic_eth.admin.ctrl.unlock',
+ [
+ 'foo',
+ chain_str,
+ address,
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+ assert r == 'foo'
+
+
+ s = celery.signature(
+ 'cic_eth.admin.ctrl.check_lock',
+ [
+ 'foo',
+ chain_str,
+ LockEnum.QUEUE,
+ address,
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+
+
+def test_lock_list(
+ default_chain_spec,
+ init_database,
+ celery_session_worker,
+ ):
+
+ chain_str = str(default_chain_spec)
+
+ # Empty list of no lock set
+ s = celery.signature(
+ 'cic_eth.queue.tx.get_lock',
+ [],
+ )
+ t = s.apply_async()
+ r = t.get()
+
+ assert len(r) == 0
+
+ # One element if lock set and no link with otx
+ tx_hash = '0x' + os.urandom(32).hex()
+ address_foo = '0x' + os.urandom(20).hex()
+ s = celery.signature(
+ 'cic_eth.admin.ctrl.lock_send',
+ [
+ 'foo',
+ chain_str,
+ address_foo,
+ tx_hash,
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+
+ s = celery.signature(
+ 'cic_eth.queue.tx.get_lock',
+ [],
+ )
+ t = s.apply_async()
+ r = t.get()
+
+ assert len(r) == 1
+ assert r[0]['tx_hash'] == None
+ assert r[0]['address'] == address_foo
+ assert r[0]['flags'] == LockEnum.SEND
+
+ # One element if lock set and link with otx, tx_hash now available
+ signed_tx = '0x' + os.urandom(128).hex()
+ otx = Otx.add(
+ 0,
+ address_foo,
+ tx_hash,
+ signed_tx,
+ )
+ s = celery.signature(
+ 'cic_eth.admin.ctrl.unlock_send',
+ [
+ 'foo',
+ chain_str,
+ address_foo,
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+
+ s = celery.signature(
+ 'cic_eth.admin.ctrl.lock_send',
+ [
+ 'foo',
+ chain_str,
+ address_foo,
+ tx_hash,
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+
+ s = celery.signature(
+ 'cic_eth.queue.tx.get_lock',
+ [],
+ )
+ t = s.apply_async()
+ r = t.get()
+
+ assert r[0]['tx_hash'] == tx_hash
+
+
+ # Two elements if two locks in place
+ address_bar = '0x' + os.urandom(20).hex()
+ tx_hash = '0x' + os.urandom(32).hex()
+ s = celery.signature(
+ 'cic_eth.admin.ctrl.lock_queue',
+ [
+ 'bar',
+ chain_str,
+ address_bar,
+ tx_hash,
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+
+ s = celery.signature(
+ 'cic_eth.queue.tx.get_lock',
+ [],
+ )
+ t = s.apply_async()
+ r = t.get()
+
+ assert len(r) == 2
+
+ # One element if filtered by address
+ s = celery.signature(
+ 'cic_eth.queue.tx.get_lock',
+ [
+ address_bar,
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+
+ assert len(r) == 1
+ assert r[0]['tx_hash'] == None
+ assert r[0]['address'] == address_bar
+ assert r[0]['flags'] == LockEnum.QUEUE
+
+ address_bogus = '0x' + os.urandom(20).hex()
+ # No elements if filtered by non-existent address
+ s = celery.signature(
+ 'cic_eth.queue.tx.get_lock',
+ [
+ address_bogus,
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+
diff --git a/apps/cic-eth/tests/tasks/test_nonce_tasks.py b/apps/cic-eth/tests/tasks/test_nonce_tasks.py
new file mode 100644
index 00000000..0f3e2685
--- /dev/null
+++ b/apps/cic-eth/tests/tasks/test_nonce_tasks.py
@@ -0,0 +1,49 @@
+# third-party imports
+import celery
+
+# local imports
+from cic_eth.admin.nonce import shift_nonce
+from cic_eth.queue.tx import create as queue_create
+from cic_eth.eth.tx import otx_cache_parse_tx
+from cic_eth.eth.task import sign_tx
+
+def test_shift_nonce(
+ default_chain_spec,
+ init_database,
+ init_w3,
+ celery_session_worker,
+ ):
+
+ chain_str = str(default_chain_spec)
+
+ tx_hashes = []
+ for i in range(5):
+ tx = {
+ 'from': init_w3.eth.accounts[0],
+ 'to': init_w3.eth.accounts[i],
+ 'nonce': i,
+ 'gas': 21000,
+ 'gasPrice': 1000000,
+ 'value': 128,
+ 'chainId': default_chain_spec.chain_id(),
+ 'data': '',
+ }
+
+ (tx_hash_hex, tx_signed_raw_hex) = sign_tx(tx, chain_str)
+ queue_create(tx['nonce'], init_w3.eth.accounts[0], tx_hash_hex, tx_signed_raw_hex, chain_str)
+ otx_cache_parse_tx(tx_hash_hex, tx_signed_raw_hex, chain_str)
+ tx_hashes.append(tx_hash_hex)
+
+ s = celery.signature(
+ 'cic_eth.admin.nonce.shift_nonce',
+ [
+ chain_str,
+ tx_hashes[2],
+ ],
+ queue=None,
+ )
+ t = s.apply_async()
+ r = t.get()
+ for _ in t.collect():
+ pass
+ assert t.successful()
diff --git a/apps/cic-eth/tests/tasks/test_otx_tasks.py b/apps/cic-eth/tests/tasks/test_otx_tasks.py
new file mode 100644
index 00000000..44ed3024
--- /dev/null
+++ b/apps/cic-eth/tests/tasks/test_otx_tasks.py
@@ -0,0 +1,174 @@
+# standard imports
+import os
+import logging
+
+# third-party imports
+import pytest
+import celery
+from cic_registry import zero_address
+
+# local imports
+from cic_eth.db.models.otx import Otx
+from cic_eth.db.models.tx import TxCache
+from cic_eth.db.enum import StatusEnum
+
+logg = logging.getLogger()
+
+# TODO: Refactor to use test vector decorator
+def test_status_success(
+ init_w3,
+ init_database,
+ celery_session_worker,
+ ):
+
+ tx_hash = '0x' + os.urandom(32).hex()
+ signed_tx = '0x' + os.urandom(128).hex()
+ account = '0x' + os.urandom(20).hex()
+
+ otx = Otx(0, init_w3.eth.accounts[0], tx_hash, signed_tx)
+ init_database.add(otx)
+ init_database.commit()
+ assert otx.status == StatusEnum.PENDING
+
+ txc = TxCache(tx_hash, account, init_w3.eth.accounts[0], zero_address, zero_address, 13, 13)
+ init_database.add(txc)
+ init_database.commit()
+
+ s = celery.signature(
+ 'cic_eth.queue.tx.set_sent_status',
+ [tx_hash],
+ )
+ t = s.apply_async()
+ t.get()
+ assert t.successful()
+ init_database.refresh(otx)
+ assert otx.status == StatusEnum.SENT
+
+ s = celery.signature(
+ 'cic_eth.queue.tx.set_final_status',
+ [tx_hash, 13],
+ )
+ t = s.apply_async()
+ t.get()
+ assert t.successful()
+ init_database.refresh(otx)
+ assert otx.status == StatusEnum.SUCCESS
+
+
+def test_status_tempfail_resend(
+ init_w3,
+ init_database,
+ celery_session_worker,
+ ):
+
+ tx_hash = '0x' + os.urandom(32).hex()
+ signed_tx = '0x' + os.urandom(128).hex()
+ account = '0x' + os.urandom(20).hex()
+
+ otx = Otx(0, init_w3.eth.accounts[0], tx_hash, signed_tx)
+ init_database.add(otx)
+ init_database.commit()
+
+ txc = TxCache(tx_hash, account, init_w3.eth.accounts[0], zero_address, zero_address, 13, 13)
+ init_database.add(txc)
+ init_database.commit()
+
+ s = celery.signature(
+ 'cic_eth.queue.tx.set_sent_status',
+ [tx_hash, True],
+ )
+ t = s.apply_async()
+ t.get()
+ assert t.successful()
+ init_database.refresh(otx)
+ assert otx.status == StatusEnum.SENDFAIL
+
+ s = celery.signature(
+ 'cic_eth.queue.tx.set_sent_status',
+ [tx_hash],
+ )
+ t = s.apply_async()
+ t.get()
+ assert t.successful()
+ init_database.refresh(otx)
+ assert otx.status == StatusEnum.SENT
+
+
+
+def test_status_fail(
+ init_w3,
+ init_database,
+ celery_session_worker,
+ ):
+
+ tx_hash = '0x' + os.urandom(32).hex()
+ signed_tx = '0x' + os.urandom(128).hex()
+ account = '0x' + os.urandom(20).hex()
+
+ otx = Otx(0, init_w3.eth.accounts[0], tx_hash, signed_tx)
+ init_database.add(otx)
+ init_database.commit()
+
+ txc = TxCache(tx_hash, account, init_w3.eth.accounts[0], zero_address, zero_address, 13, 13)
+ init_database.add(txc)
+ init_database.commit()
+
+ s = celery.signature(
+ 'cic_eth.queue.tx.set_sent_status',
+ [tx_hash],
+ )
+ t = s.apply_async()
+ t.get()
+ assert t.successful()
+ init_database.refresh(otx)
+ assert otx.status == StatusEnum.SENT
+
+ s = celery.signature(
+ 'cic_eth.queue.tx.set_final_status',
+ [tx_hash, 13, True],
+ )
+ t = s.apply_async()
+ t.get()
+ assert t.successful()
+ init_database.refresh(otx)
+ assert otx.status == StatusEnum.REVERTED
+
+
+
+def test_status_fubar(
+ init_w3,
+ init_database,
+ celery_session_worker,
+ ):
+
+ tx_hash = '0x' + os.urandom(32).hex()
+ signed_tx = '0x' + os.urandom(128).hex()
+ account = '0x' + os.urandom(20).hex()
+
+ otx = Otx(0, init_w3.eth.accounts[0], tx_hash, signed_tx)
+ init_database.add(otx)
+ init_database.commit()
+
+ txc = TxCache(tx_hash, account, init_w3.eth.accounts[0], zero_address, zero_address, 13, 13)
+ init_database.add(txc)
+ init_database.commit()
+
+ s = celery.signature(
+ 'cic_eth.queue.tx.set_sent_status',
+ [tx_hash],
+ )
+ t = s.apply_async()
+ t.get()
+ assert t.successful()
+ init_database.refresh(otx)
+ assert otx.status == StatusEnum.SENT
+
+ s = celery.signature(
+ 'cic_eth.queue.tx.set_fubar',
+ [tx_hash],
+ )
+ t = s.apply_async()
+ t.get()
+ assert t.successful()
+ init_database.refresh(otx)
+ assert otx.status == StatusEnum.FUBAR
diff --git a/apps/cic-eth/tests/tasks/test_states.py b/apps/cic-eth/tests/tasks/test_states.py
new file mode 100644
index 00000000..99ad4914
--- /dev/null
+++ b/apps/cic-eth/tests/tasks/test_states.py
@@ -0,0 +1,125 @@
+# standard imports
+import logging
+import time
+
+# third-party imports
+import celery
+
+# local imports
+from cic_eth.db.models.base import SessionBase
+from cic_eth.db.models.otx import Otx
+from cic_eth.db.enum import StatusEnum
+from cic_eth.eth.task import sign_and_register_tx
+
+logg = logging.getLogger()
+
+
+def test_states_initial(
+ init_w3,
+ init_database,
+ init_eth_account_roles,
+ celery_session_worker,
+ ):
+ tx = {
+ 'from': init_w3.eth.accounts[0],
+ 'to': init_w3.eth.accounts[1],
+ 'nonce': 42,
+ 'gas': 21000,
+ 'gasPrice': 1000000,
+ 'value': 128,
+ 'chainId': 666,
+ 'data': '',
+ }
+ (tx_hash_hex, tx_raw_signed_hex) = sign_and_register_tx(tx, 'Foo:666', None)
+
+ otx = init_database.query(Otx).filter(Otx.tx_hash==tx_hash_hex).first()
+ assert otx.status == StatusEnum.PENDING.value
+
+ s = celery.signature(
+ 'cic_eth.eth.tx.check_gas',
+ [
+ [tx_hash_hex],
+ 'Foo:666',
+ [tx_raw_signed_hex],
+ init_w3.eth.accounts[0],
+ 8000000,
+ ],
+ queue=None,
+ )
+ t = s.apply_async()
+ r = t.get()
+ for c in t.collect():
+ pass
+ assert t.successful()
+
+ session = SessionBase.create_session()
+ otx = session.query(Otx).filter(Otx.tx_hash==tx_hash_hex).first()
+ assert otx.status == StatusEnum.READYSEND.value
+
+ otx.waitforgas(session=session)
+ session.commit()
+
+ s = celery.signature(
+ 'cic_eth.eth.tx.check_gas',
+ [
+ [tx_hash_hex],
+ 'Foo:666',
+ [tx_raw_signed_hex],
+ init_w3.eth.accounts[0],
+ 8000000,
+ ],
+ queue=None,
+ )
+ t = s.apply_async()
+ r = t.get()
+ for c in t.collect():
+ pass
+ assert t.successful()
+
+ session = SessionBase.create_session()
+ otx = session.query(Otx).filter(Otx.tx_hash==tx_hash_hex).first()
+ assert otx.status == StatusEnum.READYSEND.value
+
+
+def test_states_failed(
+ init_w3,
+ init_database,
+ init_eth_account_roles,
+ celery_session_worker,
+ ):
+ tx = {
+ 'from': init_w3.eth.accounts[0],
+ 'to': init_w3.eth.accounts[1],
+ 'nonce': 42,
+ 'gas': 21000,
+ 'gasPrice': 1000000,
+ 'value': 128,
+ 'chainId': 666,
+ 'data': '',
+ }
+ (tx_hash_hex, tx_raw_signed_hex) = sign_and_register_tx(tx, 'Foo:666', None)
+
+ otx = init_database.query(Otx).filter(Otx.tx_hash==tx_hash_hex).first()
+ otx.sendfail(session=init_database)
+ init_database.add(otx)
+ init_database.commit()
+
+ s = celery.signature(
+ 'cic_eth.eth.tx.check_gas',
+ [
+ [tx_hash_hex],
+ 'Foo:666',
+ [tx_raw_signed_hex],
+ init_w3.eth.accounts[0],
+ 8000000,
+ ],
+ queue=None,
+ )
+ t = s.apply_async()
+ r = t.get()
+ for c in t.collect():
+ pass
+ assert t.successful()
+
+ otx = init_database.query(Otx).filter(Otx.tx_hash==tx_hash_hex).first()
+ assert otx.status == StatusEnum.RETRY.value
diff --git a/apps/cic-eth/tests/tasks/test_token_tasks.py b/apps/cic-eth/tests/tasks/test_token_tasks.py
new file mode 100644
index 00000000..1c5f860d
--- /dev/null
+++ b/apps/cic-eth/tests/tasks/test_token_tasks.py
@@ -0,0 +1,42 @@
+# standard imports
+import logging
+
+# third-party imports
+import celery
+
+# local imports
+from cic_eth.eth.token import TokenTxFactory
+
+
+logg = logging.getLogger()
+
+
+def test_approve(
+ init_rpc,
+ default_chain_spec,
+ celery_session_worker,
+ bancor_tokens,
+ bancor_registry,
+ cic_registry,
+ ):
+
+ s = celery.signature(
+ 'cic_eth.eth.token.approve',
+ [
+ [
+ {
+ 'address': bancor_tokens[0],
+ },
+ ],
+ init_rpc.w3.eth.accounts[0],
+ init_rpc.w3.eth.accounts[1],
+ 1024,
+ str(default_chain_spec),
+ ],
+ )
+ t = s.apply_async()
+ t.get()
+ for r in t.collect():
+ logg.debug('result {}'.format(r))
+
+ assert t.successful()
diff --git a/apps/cic-eth/tests/tasks/test_transfer_approval.py b/apps/cic-eth/tests/tasks/test_transfer_approval.py
new file mode 100644
index 00000000..574cd4c3
--- /dev/null
+++ b/apps/cic-eth/tests/tasks/test_transfer_approval.py
@@ -0,0 +1,76 @@
+# standard imports
+import logging
+import time
+
+# third-party imports
+from erc20_approval_escrow import TransferApproval
+import celery
+import sha3
+
+# local imports
+from cic_eth.eth.token import TokenTxFactory
+
+logg = logging.getLogger()
+
+
+# BUG: transaction receipt only found sometimes
+def test_transfer_approval(
+ default_chain_spec,
+ transfer_approval,
+ bancor_tokens,
+ w3_account_roles,
+ eth_empty_accounts,
+ cic_registry,
+ init_database,
+ celery_session_worker,
+ init_eth_tester,
+ init_w3,
+ ):
+
+ s = celery.signature(
+ 'cic_eth.eth.request.transfer_approval_request',
+ [
+ [
+ {
+ 'address': bancor_tokens[0],
+ },
+ ],
+ w3_account_roles['eth_account_sarafu_owner'],
+ eth_empty_accounts[0],
+ 1024,
+ str(default_chain_spec),
+ ],
+ )
+
+ s_send = celery.signature(
+ 'cic_eth.eth.tx.send',
+ [
+ str(default_chain_spec),
+ ],
+
+ )
+ s.link(s_send)
+ t = s.apply_async()
+
+ tx_signed_raws = t.get()
+ for r in t.collect():
+ logg.debug('result {}'.format(r))
+
+ assert t.successful()
+
+ init_eth_tester.mine_block()
+
+ h = sha3.keccak_256()
+ tx_signed_raw = tx_signed_raws[0]
+ tx_signed_raw_bytes = bytes.fromhex(tx_signed_raw[2:])
+ h.update(tx_signed_raw_bytes)
+ tx_hash = h.digest()
+ rcpt = init_w3.eth.getTransactionReceipt(tx_hash)
+
+ assert rcpt.status == 1
+
+ a = TransferApproval(init_w3, transfer_approval)
+ assert a.last_serial() == 1
+
+ logg.debug('requests {}'.format(a.requests(1)['serial']))
+
diff --git a/apps/cic-eth/tests/tasks/test_tx_tasks.py b/apps/cic-eth/tests/tasks/test_tx_tasks.py
new file mode 100644
index 00000000..82f5a18b
--- /dev/null
+++ b/apps/cic-eth/tests/tasks/test_tx_tasks.py
@@ -0,0 +1,168 @@
+# standard imports
+import logging
+import os
+
+# third-party imports
+import celery
+import pytest
+
+# local imports
+import cic_eth
+from cic_eth.db.models.lock import Lock
+from cic_eth.db.enum import StatusEnum
+from cic_eth.db.enum import LockEnum
+from cic_eth.error import LockedError
+from cic_eth.queue.tx import create as queue_create
+from cic_eth.queue.tx import set_sent_status
+from cic_eth.eth.tx import cache_gas_refill_data
+from cic_eth.error import PermanentTxError
+from cic_eth.queue.tx import get_tx
+from cic_eth.eth.task import sign_tx
+
+logg = logging.getLogger()
+
+
+# TODO: There is no
+def test_send_reject(
+ default_chain_spec,
+ init_w3,
+ mocker,
+ init_database,
+ celery_session_worker,
+ ):
+
+ nonce = init_w3.eth.getTransactionCount(init_w3.eth.accounts[0], 'pending')
+ tx = {
+ 'from': init_w3.eth.accounts[0],
+ 'to': init_w3.eth.accounts[1],
+ 'nonce': nonce,
+ 'gas': 21000,
+ 'gasPrice': 1000000,
+ 'value': 128,
+ 'chainId': default_chain_spec.chain_id(),
+ 'data': '',
+ }
+
+ chain_str = str(default_chain_spec)
+
+ (tx_hash_hex, tx_signed_raw_hex) = sign_tx(tx, chain_str)
+ queue_create(tx['nonce'], tx['from'], tx_hash_hex, tx_signed_raw_hex, str(default_chain_spec))
+ cache_gas_refill_data(tx_hash_hex, tx)
+ s = celery.signature(
+ 'cic_eth.eth.tx.send',
+ [
+ [tx_signed_raw_hex],
+ chain_str,
+ ],
+ )
+ t = s.apply_async()
+ r = t.get()
+
+
+def test_sync_tx(
+ default_chain_spec,
+ init_database,
+ init_w3,
+ init_wallet_extension,
+ init_eth_tester,
+ celery_session_worker,
+ eth_empty_accounts,
+ ):
+
+ nonce = init_w3.eth.getTransactionCount(init_w3.eth.accounts[0], 'pending')
+ tx = {
+ 'from': init_w3.eth.accounts[0],
+ 'to': init_w3.eth.accounts[1],
+ 'nonce': nonce,
+ 'gas': 21000,
+ 'gasPrice': 1000000,
+ 'value': 128,
+ 'chainId': default_chain_spec.chain_id(),
+ 'data': '',
+ }
+
+ chain_str = str(default_chain_spec)
+
+ (tx_hash_hex, tx_signed_raw_hex) = sign_tx(tx, chain_str)
+ queue_create(tx['nonce'], tx['from'], tx_hash_hex, tx_signed_raw_hex, str(default_chain_spec))
+ cache_gas_refill_data(tx_hash_hex, tx)
+
+ init_w3.eth.send_raw_transaction(tx_signed_raw_hex)
+
+ s = celery.signature(
+ 'cic_eth.eth.tx.sync_tx',
+ [
+ tx_hash_hex,
+ chain_str,
+ ],
+ queue=None
+ )
+ t = s.apply_async()
+ r = t.get()
+ for _ in t.collect():
+ pass
+ assert t.successful()
+
+ tx_dict = get_tx(tx_hash_hex)
+ assert tx_dict['status'] == StatusEnum.SENT
+
+ init_eth_tester.mine_block()
+
+ s = celery.signature(
+ 'cic_eth.eth.tx.sync_tx',
+ [
+ tx_hash_hex,
+ chain_str,
+ ],
+ queue=None
+ )
+ t = s.apply_async()
+ r = t.get()
+ for _ in t.collect():
+ pass
+ assert t.successful()
+
+ tx_dict = get_tx(tx_hash_hex)
+ assert tx_dict['status'] == StatusEnum.SUCCESS
+
+
+
+def test_resume_tx(
+ default_chain_spec,
+ init_database,
+ init_w3,
+ celery_session_worker,
+ ):
+
+ tx = {
+ 'from': init_w3.eth.accounts[0],
+ 'to': init_w3.eth.accounts[1],
+ 'nonce': 42 ,
+ 'gas': 21000,
+ 'gasPrice': 1000000,
+ 'value': 128,
+ 'chainId': default_chain_spec.chain_id(),
+ 'data': '',
+ }
+ tx_signed = init_w3.eth.sign_transaction(tx)
+ tx_hash = init_w3.keccak(hexstr=tx_signed['raw'])
+ tx_hash_hex = tx_hash.hex()
+ queue_create(tx['nonce'], tx['from'], tx_hash_hex, tx_signed['raw'], str(default_chain_spec))
+ cache_gas_refill_data(tx_hash_hex, tx)
+
+ set_sent_status(tx_hash_hex, True)
+
+ s = celery.signature(
+ 'cic_eth.eth.tx.resume_tx',
+ [
+ tx_hash_hex,
+ str(default_chain_spec),
+ ],
+ )
+ t = s.apply_async()
+ t.get()
+ for r in t.collect():
+ logg.debug('collect {}'.format(r))
+ assert t.successful()
+
+
diff --git a/apps/cic-eth/tests/test_basic.py b/apps/cic-eth/tests/test_basic.py
new file mode 100644
index 00000000..6c3bde7e
--- /dev/null
+++ b/apps/cic-eth/tests/test_basic.py
@@ -0,0 +1,10 @@
+
+def test_default(
+ init_database,
+ ):
+ pass
+
+def test_w3(
+ init_w3,
+ ):
+ a = init_w3.eth.accounts[0]
diff --git a/apps/cic-eth/tests/test_sign.py b/apps/cic-eth/tests/test_sign.py
new file mode 100644
index 00000000..57897e65
--- /dev/null
+++ b/apps/cic-eth/tests/test_sign.py
@@ -0,0 +1,27 @@
+# standard imports
+import logging
+import sha3
+
+# third-party imports
+import pytest
+
+logg = logging.getLogger()
+
+
+def test_sign(
+ init_w3,
+ init_eth_tester,
+ ):
+ nonce = init_w3.eth.getTransactionCount(init_w3.eth.accounts[0], 'pending')
+ tx = init_w3.eth.sign_transaction({
+ 'from': init_w3.eth.accounts[0],
+ 'to': init_w3.eth.accounts[1],
+ 'nonce': nonce,
+ 'value': 101,
+ 'gasPrice': 2000000000,
+ 'gas': 21000,
+ 'data': '',
+ 'chainId': 8995,
+ })
+ tx_hash = init_w3.eth.send_raw_transaction(tx['raw'])
+ logg.debug('have tx {}'.format(tx_hash))
diff --git a/apps/cic-eth/tests/testdata/abi/AccountRegistry.json b/apps/cic-eth/tests/testdata/abi/AccountRegistry.json
new file mode 100644
index 00000000..59de177f
--- /dev/null
+++ b/apps/cic-eth/tests/testdata/abi/AccountRegistry.json
@@ -0,0 +1 @@
+[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"addedAccount","type":"address"},{"indexed":true,"internalType":"uint256","name":"accountIndex","type":"uint256"}],"name":"AccountAdded","type":"event"},{"inputs":[{"internalType":"uint256","name":"_idx","type":"uint256"}],"name":"accounts","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"accountsIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"add","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_writer","type":"address"}],"name":"addWriter","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"count","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_writer","type":"address"}],"name":"deleteWriter","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_account","type":"address"}],"name":"have","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}]
diff --git a/apps/cic-eth/tests/testdata/abi/Converter.json b/apps/cic-eth/tests/testdata/abi/Converter.json
new file mode 100644
index 00000000..89c75dd9
--- /dev/null
+++ b/apps/cic-eth/tests/testdata/abi/Converter.json
@@ -0,0 +1 @@
+[{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_reserveToken","type":"address"}],"name":"reserveBalance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"reserveRatio","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"reserveTokenCount","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"reserveTokens","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_reserveToken","type":"address"}],"name":"reserveWeight","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint32","name":"_conversionFee","type":"uint32"}],"name":"setConversionFee","outputs":[],"stateMutability":"nonpayable","type":"function"}]
diff --git a/apps/cic-eth/tests/testdata/abi/ConverterRegistry.json b/apps/cic-eth/tests/testdata/abi/ConverterRegistry.json
new file mode 100644
index 00000000..b405748a
--- /dev/null
+++ b/apps/cic-eth/tests/testdata/abi/ConverterRegistry.json
@@ -0,0 +1 @@
+[{"inputs":[],"name":"getConvertibleTokens","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint16","name":"_type","type":"uint16"},{"internalType":"string","name":"_name","type":"string"},{"internalType":"string","name":"_symbol","type":"string"},{"internalType":"uint8","name":"_decimals","type":"uint8"},{"internalType":"uint32","name":"_maxConversionFee","type":"uint32"},{"internalType":"address[]","name":"_reserveTokens","type":"address[]"},{"internalType":"uint32[]","name":"_reserveWeights","type":"uint32[]"}],"name":"newConverter","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"nonpayable","type":"function"}]
diff --git a/apps/cic-eth/tests/testdata/abi/ERC20.json b/apps/cic-eth/tests/testdata/abi/ERC20.json
new file mode 100644
index 00000000..d50ea47a
--- /dev/null
+++ b/apps/cic-eth/tests/testdata/abi/ERC20.json
@@ -0,0 +1 @@
+[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_owner","type":"address"},{"indexed":true,"internalType":"address","name":"_spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"_value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_from","type":"address"},{"indexed":true,"internalType":"address","name":"_to","type":"address"},{"indexed":false,"internalType":"uint256","name":"_value","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[{"internalType":"address","name":"_owner","type":"address"},{"internalType":"address","name":"_spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_spender","type":"address"},{"internalType":"uint256","name":"_value","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_value","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_from","type":"address"},{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_value","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"}]
diff --git a/apps/cic-eth/tests/testdata/abi/Faucet.json b/apps/cic-eth/tests/testdata/abi/Faucet.json
new file mode 100644
index 00000000..0c437e69
--- /dev/null
+++ b/apps/cic-eth/tests/testdata/abi/Faucet.json
@@ -0,0 +1 @@
+[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_recipient","type":"address"},{"indexed":true,"internalType":"address","name":"_token","type":"address"},{"indexed":false,"internalType":"uint256","name":"_value","type":"uint256"}],"name":"FaucetFail","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_recipient","type":"address"},{"indexed":true,"internalType":"address","name":"_token","type":"address"},{"indexed":false,"internalType":"uint256","name":"_value","type":"uint256"}],"name":"FaucetUsed","type":"event"},{"inputs":[],"name":"amount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_recipient","type":"address"}],"name":"giveTo","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"setAmount","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"token","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}]
diff --git a/apps/cic-eth/tests/testdata/abi/Network.json b/apps/cic-eth/tests/testdata/abi/Network.json
new file mode 100644
index 00000000..68e237a4
--- /dev/null
+++ b/apps/cic-eth/tests/testdata/abi/Network.json
@@ -0,0 +1 @@
+[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_smartToken","type":"address"},{"indexed":true,"internalType":"address","name":"_fromToken","type":"address"},{"indexed":true,"internalType":"address","name":"_toToken","type":"address"},{"indexed":false,"internalType":"uint256","name":"_fromAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_toAmount","type":"uint256"},{"indexed":false,"internalType":"address","name":"_trader","type":"address"}],"name":"Conversion","type":"event"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"convert","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"rateByPath","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"}]
diff --git a/apps/cic-eth/tests/testdata/abi/Registry.json b/apps/cic-eth/tests/testdata/abi/Registry.json
new file mode 100644
index 00000000..aa058777
--- /dev/null
+++ b/apps/cic-eth/tests/testdata/abi/Registry.json
@@ -0,0 +1 @@
+[{"inputs":[{"internalType":"bytes32","name":"_identifier","type":"bytes32"}],"name":"chainOf","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_chain","type":"bytes32"}],"name":"configSumOf","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"identifiers","outputs":[{"internalType":"bytes32[]","name":"","type":"bytes32[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"seal","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_identifier","type":"bytes32"},{"internalType":"address","name":"_address","type":"address"},{"internalType":"bytes32","name":"_chainDescriptor","type":"bytes32"},{"internalType":"bytes32","name":"_chainConfig","type":"bytes32"}],"name":"set","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"}]
diff --git a/apps/cic-eth/tests/testdata/abi/RegistryClient.json b/apps/cic-eth/tests/testdata/abi/RegistryClient.json
new file mode 100644
index 00000000..2b3baa8a
--- /dev/null
+++ b/apps/cic-eth/tests/testdata/abi/RegistryClient.json
@@ -0,0 +1 @@
+[{"inputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"name":"addressOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}]
diff --git a/apps/cic-eth/tests/testdata/abi/TransferApproval.json b/apps/cic-eth/tests/testdata/abi/TransferApproval.json
new file mode 100644
index 00000000..dcbf2d68
--- /dev/null
+++ b/apps/cic-eth/tests/testdata/abi/TransferApproval.json
@@ -0,0 +1 @@
+[{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"serial","type":"uint256"}],"name":"NewExecution","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"serial","type":"uint256"}],"name":"NewRejection","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_sender","type":"address"},{"indexed":true,"internalType":"address","name":"_recipient","type":"address"},{"indexed":true,"internalType":"address","name":"_token","type":"address"},{"indexed":false,"internalType":"uint256","name":"_value","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_serial","type":"uint256"}],"name":"NewRequest","type":"event"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"approvers","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_serial","type":"uint256"}],"name":"execute","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_serial","type":"uint256"}],"name":"reject","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_recipient","type":"address"},{"internalType":"address","name":"_token","type":"address"},{"internalType":"uint256","name":"_value","type":"uint256"}],"name":"request","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"requests","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"serial","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"}]
diff --git a/apps/cic-eth/tests/testdata/bancor/BancorFormula.json b/apps/cic-eth/tests/testdata/bancor/BancorFormula.json
new file mode 100644
index 00000000..460e0089
--- /dev/null
+++ b/apps/cic-eth/tests/testdata/bancor/BancorFormula.json
@@ -0,0 +1,151530 @@
+{
+ "contractName": "BancorFormula",
+ "abi": [
+ {
+ "inputs": [],
+ "name": "init",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_supply",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_reserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_reserveWeight",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "purchaseTargetAmount",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_supply",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_reserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_reserveWeight",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "saleTargetAmount",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_sourceReserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_sourceReserveWeight",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_targetReserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_targetReserveWeight",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "crossReserveTargetAmount",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_supply",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_reserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_reserveRatio",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "fundCost",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_supply",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_reserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_reserveRatio",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "fundSupplyAmount",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_supply",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_reserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_reserveRatio",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "liquidateReserveAmount",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_primaryReserveStakedBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_primaryReserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_secondaryReserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_reserveRateNumerator",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_reserveRateDenominator",
+ "type": "uint256"
+ }
+ ],
+ "name": "balancedWeights",
+ "outputs": [
+ {
+ "internalType": "uint32",
+ "name": "",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint32",
+ "name": "",
+ "type": "uint32"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_supply",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_reserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_reserveWeight",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "calculatePurchaseReturn",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_supply",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_reserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_reserveWeight",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "calculateSaleReturn",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_sourceReserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_sourceReserveWeight",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_targetReserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_targetReserveWeight",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "calculateCrossReserveReturn",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_sourceReserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_sourceReserveWeight",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_targetReserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_targetReserveWeight",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "calculateCrossConnectorReturn",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_supply",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_reserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_reserveRatio",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "calculateFundCost",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_supply",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_reserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_reserveRatio",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "calculateLiquidateReturn",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_supply",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_reserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_reserveWeight",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "purchaseRate",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_supply",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_reserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_reserveWeight",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "saleRate",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_sourceReserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_sourceReserveWeight",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_targetReserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_targetReserveWeight",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "crossReserveRate",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_supply",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_reserveBalance",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint32",
+ "name": "_reserveRatio",
+ "type": "uint32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "liquidateRate",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ }
+ ],
+ "metadata": "{\"compiler\":{\"version\":\"0.6.12+commit.27d51765\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_primaryReserveStakedBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_primaryReserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_secondaryReserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_reserveRateNumerator\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_reserveRateDenominator\",\"type\":\"uint256\"}],\"name\":\"balancedWeights\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_sourceReserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_sourceReserveWeight\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_targetReserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_targetReserveWeight\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"calculateCrossConnectorReturn\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_sourceReserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_sourceReserveWeight\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_targetReserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_targetReserveWeight\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"calculateCrossReserveReturn\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_supply\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_reserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_reserveRatio\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"calculateFundCost\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_supply\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_reserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_reserveRatio\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"calculateLiquidateReturn\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_supply\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_reserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_reserveWeight\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"calculatePurchaseReturn\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_supply\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_reserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_reserveWeight\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"calculateSaleReturn\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_sourceReserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_sourceReserveWeight\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_targetReserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_targetReserveWeight\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"crossReserveRate\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_sourceReserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_sourceReserveWeight\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_targetReserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_targetReserveWeight\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"crossReserveTargetAmount\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_supply\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_reserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_reserveRatio\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"fundCost\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_supply\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_reserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_reserveRatio\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"fundSupplyAmount\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"init\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_supply\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_reserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_reserveRatio\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"liquidateRate\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_supply\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_reserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_reserveRatio\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"liquidateReserveAmount\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_supply\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_reserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_reserveWeight\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"purchaseRate\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_supply\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_reserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_reserveWeight\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"purchaseTargetAmount\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_supply\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_reserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_reserveWeight\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"saleRate\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_supply\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_reserveBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_reserveWeight\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"saleTargetAmount\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{\"balancedWeights(uint256,uint256,uint256,uint256,uint256)\":{\"details\":\"The arbitrage incentive is to convert to the point where the on-chain price is equal to the off-chain price. We want this operation to also impact the primary reserve balance becoming equal to the primary reserve staked balance. In other words, we want the arbitrager to convert the difference between the reserve balance and the reserve staked balance. Formula input: - let t denote the primary reserve token staked balance - let s denote the primary reserve token balance - let r denote the secondary reserve token balance - let q denote the numerator of the rate between the tokens - let p denote the denominator of the rate between the tokens Where p primary tokens are equal to q secondary tokens Formula output: - compute x = W(t / r * q / p * log(s / t)) / log(s / t) - return x / (1 + x) as the weight of the primary reserve token - return 1 / (1 + x) as the weight of the secondary reserve token Where W is the Lambert W Function If the rate-provider provides the rates for a common unit, for example: - P = 2 ==> 2 primary reserve tokens = 1 ether - Q = 3 ==> 3 secondary reserve tokens = 1 ether Then you can simply use p = P and q = Q If the rate-provider provides the rates for a single unit, for example: - P = 2 ==> 1 primary reserve token = 2 ethers - Q = 3 ==> 1 secondary reserve token = 3 ethers Then you can simply use p = Q and q = P\",\"params\":{\"_primaryReserveBalance\":\"the primary reserve token balance\",\"_primaryReserveStakedBalance\":\"the primary reserve token staked balance\",\"_reserveRateDenominator\":\"the denominator of the rate between the tokens Note that `numerator / denominator` should represent the amount of secondary tokens equal to one primary token\",\"_reserveRateNumerator\":\"the numerator of the rate between the tokens\",\"_secondaryReserveBalance\":\"the secondary reserve token balance\"},\"returns\":{\"_0\":\"the weight of the primary reserve token and the weight of the secondary reserve token, both in ppm (0-1000000)\"}},\"calculateCrossConnectorReturn(uint256,uint32,uint256,uint32,uint256)\":{\"details\":\"deprecated, backward compatibility\"},\"calculateCrossReserveReturn(uint256,uint32,uint256,uint32,uint256)\":{\"details\":\"deprecated, backward compatibility\"},\"calculateFundCost(uint256,uint256,uint32,uint256)\":{\"details\":\"deprecated, backward compatibility\"},\"calculateLiquidateReturn(uint256,uint256,uint32,uint256)\":{\"details\":\"deprecated, backward compatibility\"},\"calculatePurchaseReturn(uint256,uint256,uint32,uint256)\":{\"details\":\"deprecated, backward compatibility\"},\"calculateSaleReturn(uint256,uint256,uint32,uint256)\":{\"details\":\"deprecated, backward compatibility\"},\"crossReserveRate(uint256,uint32,uint256,uint32,uint256)\":{\"details\":\"deprecated, backward compatibility\"},\"crossReserveTargetAmount(uint256,uint32,uint256,uint32,uint256)\":{\"details\":\"given two reserve balances/weights and a sell amount (in the first reserve token), calculates the target amount for a conversion from the source reserve token to the target reserve token Formula: return = _targetReserveBalance * (1 - (_sourceReserveBalance / (_sourceReserveBalance + _amount)) ^ (_sourceReserveWeight / _targetReserveWeight))\",\"params\":{\"_amount\":\"source reserve amount\",\"_sourceReserveBalance\":\"source reserve balance\",\"_sourceReserveWeight\":\"source reserve weight, represented in ppm (1-1000000)\",\"_targetReserveBalance\":\"target reserve balance\",\"_targetReserveWeight\":\"target reserve weight, represented in ppm (1-1000000)\"},\"returns\":{\"_0\":\"target reserve amount\"}},\"fundCost(uint256,uint256,uint32,uint256)\":{\"details\":\"given a smart token supply, reserve balance, reserve ratio and an amount of requested smart tokens, calculates the amount of reserve tokens required for purchasing the given amount of smart tokens Formula: return = _reserveBalance * (((_supply + _amount) / _supply) ^ (MAX_WEIGHT / _reserveRatio) - 1)\",\"params\":{\"_amount\":\"requested amount of smart tokens\",\"_reserveBalance\":\"reserve balance\",\"_reserveRatio\":\"reserve ratio, represented in ppm (2-2000000)\",\"_supply\":\"smart token supply\"},\"returns\":{\"_0\":\"reserve token amount\"}},\"fundSupplyAmount(uint256,uint256,uint32,uint256)\":{\"details\":\"given a smart token supply, reserve balance, reserve ratio and an amount of reserve tokens to fund with, calculates the amount of smart tokens received for purchasing with the given amount of reserve tokens Formula: return = _supply * ((_amount / _reserveBalance + 1) ^ (_reserveRatio / MAX_WEIGHT) - 1)\",\"params\":{\"_amount\":\"amount of reserve tokens to fund with\",\"_reserveBalance\":\"reserve balance\",\"_reserveRatio\":\"reserve ratio, represented in ppm (2-2000000)\",\"_supply\":\"smart token supply\"},\"returns\":{\"_0\":\"smart token amount\"}},\"init()\":{\"details\":\"should be executed after construction (too large for the constructor)\"},\"liquidateRate(uint256,uint256,uint32,uint256)\":{\"details\":\"deprecated, backward compatibility\"},\"liquidateReserveAmount(uint256,uint256,uint32,uint256)\":{\"details\":\"given a smart token supply, reserve balance, reserve ratio and an amount of smart tokens to liquidate, calculates the amount of reserve tokens received for selling the given amount of smart tokens Formula: return = _reserveBalance * (1 - ((_supply - _amount) / _supply) ^ (MAX_WEIGHT / _reserveRatio))\",\"params\":{\"_amount\":\"amount of smart tokens to liquidate\",\"_reserveBalance\":\"reserve balance\",\"_reserveRatio\":\"reserve ratio, represented in ppm (2-2000000)\",\"_supply\":\"smart token supply\"},\"returns\":{\"_0\":\"reserve token amount\"}},\"purchaseRate(uint256,uint256,uint32,uint256)\":{\"details\":\"deprecated, backward compatibility\"},\"purchaseTargetAmount(uint256,uint256,uint32,uint256)\":{\"details\":\"given a token supply, reserve balance, weight and a deposit amount (in the reserve token), calculates the target amount for a given conversion (in the main token) Formula: return = _supply * ((1 + _amount / _reserveBalance) ^ (_reserveWeight / 1000000) - 1)\",\"params\":{\"_amount\":\"amount of reserve tokens to get the target amount for\",\"_reserveBalance\":\"reserve balance\",\"_reserveWeight\":\"reserve weight, represented in ppm (1-1000000)\",\"_supply\":\"smart token supply\"},\"returns\":{\"_0\":\"smart token amount\"}},\"saleRate(uint256,uint256,uint32,uint256)\":{\"details\":\"deprecated, backward compatibility\"},\"saleTargetAmount(uint256,uint256,uint32,uint256)\":{\"details\":\"given a token supply, reserve balance, weight and a sell amount (in the main token), calculates the target amount for a given conversion (in the reserve token) Formula: return = _reserveBalance * (1 - (1 - _amount / _supply) ^ (1000000 / _reserveWeight))\",\"params\":{\"_amount\":\"amount of smart tokens to get the target amount for\",\"_reserveBalance\":\"reserve balance\",\"_reserveWeight\":\"reserve weight, represented in ppm (1-1000000)\",\"_supply\":\"smart token supply\"},\"returns\":{\"_0\":\"reserve token amount\"}}},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/BancorFormula.sol\":\"BancorFormula\"},\"evmVersion\":\"istanbul\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":200},\"remappings\":[]},\"sources\":{\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/BancorFormula.sol\":{\"keccak256\":\"0x24ae54f35c6099ecb1cb077e96ba2a956d4ca344ed65473e04cf8bf52d65b81e\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://59f6e37cc90b585f381faebb13ff42fd18025b3f650bfa59f1c46bc226515d9a\",\"dweb:/ipfs/QmVCFUq8gqtvB1AyjRwuN331e6vR3WZeE75mBdC7p5dZgZ\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IBancorFormula.sol\":{\"keccak256\":\"0xf30c95034af4c4ec6e8a859e90cf7a0bada29a805ede76e04644107a7c677c4e\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://b48070d4abf9c4a08c39e6c494fa9efd7389aa7f8b61b283c9ba02062b1c59b6\",\"dweb:/ipfs/Qme6U7SpspFPzMH2mTyKsXCnJEAgg1vX6NNFzuykbVSY5R\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/SafeMath.sol\":{\"keccak256\":\"0x1ab7391a19ca8a3ad2f3c4a1074e080d4d76dfdb834637bdd0c1e6b6acdf28af\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://d6d8c99621ca884b72da2d84eddfec8ec8c5533915691d6eec94a07adf445608\",\"dweb:/ipfs/QmaXr6DN7VbfxfMn3PsTy7SAMgZVVXbdeaw11BsAjVL2x1\"]}},\"version\":1}",
+ "bytecode": "0x608060405234801561001057600080fd5b50613bf2806100206000396000f3fe608060405234801561001057600080fd5b50600436106101165760003560e01c80638074590a116100a2578063abfd231d11610071578063abfd231d146101cc578063e1c7392a14610378578063ebbb215814610382578063f3250fe2146103b7578063f732f1c91461020157610116565b80638074590a146102a857806394491fab146102dd5780639d11410814610236578063a11aa1b41461031a57610116565b806348d73fed116100e957806348d73fed1461016257806349f9b0f71461020157806365098bb31461023657806376cf0b561461027357806379c1b4501461023657610116565b80631da6bbfb1461011b57806329a00e7c146101625780632f55bdb51461019757806335b49af4146101cc575b600080fd5b6101506004803603608081101561013157600080fd5b5080359060208101359063ffffffff60408201351690606001356103ec565b60408051918252519081900360200190f35b6101506004803603608081101561017857600080fd5b5080359060208101359063ffffffff6040820135169060600135610405565b610150600480360360808110156101ad57600080fd5b5080359060208101359063ffffffff6040820135169060600135610413565b610150600480360360808110156101e257600080fd5b5080359060208101359063ffffffff604082013516906060013561058b565b6101506004803603608081101561021757600080fd5b5080359060208101359063ffffffff6040820135169060600135610599565b610150600480360360a081101561024c57600080fd5b5080359063ffffffff602082013581169160408101359160608201351690608001356105a7565b6101506004803603608081101561028957600080fd5b5080359060208101359063ffffffff60408201351690606001356105c2565b610150600480360360808110156102be57600080fd5b5080359060208101359063ffffffff6040820135169060600135610788565b610150600480360360a08110156102f357600080fd5b5080359063ffffffff60208201358116916040810135916060820135169060800135610904565b61034f600480360360a081101561033057600080fd5b5080359060208101359060408101359060608101359060800135610a70565b604051808363ffffffff1681526020018263ffffffff1681526020019250505060405180910390f35b610380610bf8565b005b6101506004803603608081101561039857600080fd5b5080359060208101359063ffffffff6040820135169060600135610c0a565b610150600480360360808110156103cd57600080fd5b5080359060208101359063ffffffff6040820135169060600135610d8f565b60006103fa85858585610c0a565b90505b949350505050565b60006103fa85858585610d8f565b600080851161045e576040805162461bcd60e51b81526020600482015260126024820152714552525f494e56414c49445f535550504c5960701b604482015290519081900360640190fd5b600084116104a1576040805162461bcd60e51b815260206004820152601b6024820152600080516020613b9d833981519152604482015290519081900360640190fd5b60018363ffffffff161180156104c05750621e848063ffffffff841611155b61050d576040805162461bcd60e51b81526020600482015260196024820152784552525f494e56414c49445f524553455256455f524154494f60381b604482015290519081900360640190fd5b8161051a575060006103fd565b63ffffffff8316620f4240141561054557836105368387610ec1565b8161053d57fe5b0490506103fd565b600080806105538786610f28565b9050610564818888620f4240610f71565b9093509150600060ff83166105798a86610ec1565b901c9890980398975050505050505050565b60006103fa85858585610788565b60006103fa858585856105c2565b60006105b68686868686610904565b90505b95945050505050565b600080851161060d576040805162461bcd60e51b81526020600482015260126024820152714552525f494e56414c49445f535550504c5960701b604482015290519081900360640190fd5b60008411610650576040805162461bcd60e51b815260206004820152601b6024820152600080516020613b9d833981519152604482015290519081900360640190fd5b60008363ffffffff1611801561066f5750620f424063ffffffff841611155b6106bd576040805162461bcd60e51b815260206004820152601a60248201527911549497d253959053125117d49154d154959157d5d15251d21560321b604482015290519081900360640190fd5b84821115610707576040805162461bcd60e51b815260206004820152601260248201527111549497d253959053125117d05353d5539560721b604482015290519081900360640190fd5b81610714575060006103fd565b848214156107235750826103fd565b63ffffffff8316620f4240141561073f57846105368584610ec1565b6000808387036107548882620f424089610f71565b909350915060006107658885610ec1565b905060ff831688901b848183038161077957fe5b049a9950505050505050505050565b60008085116107d3576040805162461bcd60e51b81526020600482015260126024820152714552525f494e56414c49445f535550504c5960701b604482015290519081900360640190fd5b60008411610816576040805162461bcd60e51b815260206004820152601b6024820152600080516020613b9d833981519152604482015290519081900360640190fd5b60018363ffffffff161180156108355750621e848063ffffffff841611155b610882576040805162461bcd60e51b81526020600482015260196024820152784552525f494e56414c49445f524553455256455f524154494f60381b604482015290519081900360640190fd5b848211156108cc576040805162461bcd60e51b815260206004820152601260248201527111549497d253959053125117d05353d5539560721b604482015290519081900360640190fd5b816108d9575060006103fd565b848214156108e85750826103fd565b63ffffffff8316620f4240141561073f57846105368386610ec1565b600080861180156109155750600084115b610954576040805162461bcd60e51b815260206004820152601b6024820152600080516020613b9d833981519152604482015290519081900360640190fd5b60008563ffffffff161180156109735750620f424063ffffffff861611155b8015610985575060008363ffffffff16115b801561099a5750620f424063ffffffff841611155b6109e8576040805162461bcd60e51b815260206004820152601a60248201527911549497d253959053125117d49154d154959157d5d15251d21560321b604482015290519081900360640190fd5b8263ffffffff168563ffffffff161415610a1f57610a068683610f28565b610a108584610ec1565b81610a1757fe5b0490506105b9565b60008080610a2d8986610f28565b9050610a3b818a8a89610f71565b90935091506000610a4c8885610ec1565b905060ff831688901b8481830381610a6057fe5b049b9a5050505050505050505050565b60008085871415610ace576000871180610a8a5750600085115b610ac9576040805162461bcd60e51b815260206004820152601b6024820152600080516020613b9d833981519152604482015290519081900360640190fd5b610b29565b600087118015610ade5750600086115b8015610aea5750600085115b610b29576040805162461bcd60e51b815260206004820152601b6024820152600080516020613b9d833981519152604482015290519081900360640190fd5b600084118015610b395750600083115b610b8a576040805162461bcd60e51b815260206004820152601860248201527f4552525f494e56414c49445f524553455256455f524154450000000000000000604482015290519081900360640190fd5b6000610b968886610ec1565b90506000610ba48786610ec1565b905087891015610bc757610bbc888a84846001611043565b935093505050610bee565b87891115610bdd57610bbc898984846000611043565b610be7828261110c565b9350935050505b9550959350505050565b610c00611144565b610c0861191a565b565b6000808511610c55576040805162461bcd60e51b81526020600482015260126024820152714552525f494e56414c49445f535550504c5960701b604482015290519081900360640190fd5b60008411610c98576040805162461bcd60e51b815260206004820152601b6024820152600080516020613b9d833981519152604482015290519081900360640190fd5b60018363ffffffff16118015610cb75750621e848063ffffffff841611155b610d04576040805162461bcd60e51b81526020600482015260196024820152784552525f494e56414c49445f524553455256455f524154494f60381b604482015290519081900360640190fd5b81610d11575060006103fd565b63ffffffff8316620f42401415610d4257846001610d2f8487610ec1565b0381610d3757fe5b0460010190506103fd565b60008080610d508886610f28565b9050610d618189620f424089610f71565b9093509150600060ff83166001610d788a87610ec1565b03901c889003600101945050505050949350505050565b6000808511610dda576040805162461bcd60e51b81526020600482015260126024820152714552525f494e56414c49445f535550504c5960701b604482015290519081900360640190fd5b60008411610e1d576040805162461bcd60e51b815260206004820152601b6024820152600080516020613b9d833981519152604482015290519081900360640190fd5b60008363ffffffff16118015610e3c5750620f424063ffffffff841611155b610e8a576040805162461bcd60e51b815260206004820152601a60248201527911549497d253959053125117d49154d154959157d5d15251d21560321b604482015290519081900360640190fd5b81610e97575060006103fd565b63ffffffff8316620f42401415610eb357836105368684610ec1565b600080806105538588610f28565b600082610ed057506000610f22565b82820282848281610edd57fe5b0414610f1f576040805162461bcd60e51b815260206004820152600c60248201526b4552525f4f564552464c4f5760a01b604482015290519081900360640190fd5b90505b92915050565b600082820183811015610f1f576040805162461bcd60e51b815260206004820152600c60248201526b4552525f4f564552464c4f5760a01b604482015290519081900360640190fd5b600080600160811b8610610f8457600080fd5b600080866001607f1b890281610f9657fe5b04905070015bf0a8b1457695355fb8ac404e7a79e3811015610fc257610fbb81612321565b9150610fce565b610fcb81612705565b91505b60008563ffffffff168763ffffffff16840281610fe757fe5b049050600160831b81101561100d57610fff816127b0565b607f9450945050505061103a565b600061101882612b54565b905061102d81607f0360ff1683901c82612be4565b9550935061103a92505050565b94509492505050565b6000806110508585612f7e565b9095509350600086611066896001607f1b610ec1565b8161106d57fe5b049050600070015bf0a8b1457695355fb8ac404e7a79e382106110985761109382612705565b6110a1565b6110a182612321565b90506000866110b0838a610ec1565b816110b757fe5b0490506000866110cf576110ca82613031565b6110d8565b6110d88261306e565b90506110fa6110e7828b610ec1565b6110f58a6001607f1b610ec1565b61110c565b95509550505050509550959350505050565b6000808284116111295761112084846130d2565b9150915061113d565b60008061113685876130d2565b9450925050505b9250929050565b701c35fedd14ffffffffffffffffffffffff602055701b0ce43b323fffffffffffffffffffffff6021557019f0028ec1ffffffffffffffffffffffff6022557018ded91f0e7fffffffffffffffffffffff6023557017d8ec7f0417ffffffffffffffffffffff6024557016ddc6556cdbffffffffffffffffffffff6025557015ecf52776a1ffffffffffffffffffffff6026557015060c256cb2ffffffffffffffffffffff602755701428a2f98d72ffffffffffffffffffffff6028557013545598e5c23fffffffffffffffffffff602955701288c4161ce1dfffffffffffffffffffff602a557011c592761c666fffffffffffffffffffff602b5570110a688680a757ffffffffffffffffffff602c55701056f1b5bedf77ffffffffffffffffffff602d55700faadceceeff8bffffffffffffffffffff602e55700f05dc6b27edadffffffffffffffffffff602f55700e67a5a25da4107fffffffffffffffffff603055700dcff115b14eedffffffffffffffffffff603155700d3e7a392431239fffffffffffffffffff603255700cb2ff529eb71e4fffffffffffffffffff603355700c2d415c3db974afffffffffffffffffff603455700bad03e7d883f69bffffffffffffffffff603555700b320d03b2c343d5ffffffffffffffffff603655700abc25204e02828dffffffffffffffffff603755700a4b16f74ee4bb207fffffffffffffffff6038557009deaf736ac1f569ffffffffffffffffff603955700976bd9952c7aa957fffffffffffffffff603a557009131271922eaa606fffffffffffffffff603b557008b380f3558668c46fffffffffffffffff603c55700857ddf0117efa215bffffffffffffffff603d557007ffffffffffffffffffffffffffffffff603e557007abbf6f6abb9d087fffffffffffffffff603f5570075af62cbac95f7dfa7fffffffffffffff60405570070d7fb7452e187ac13fffffffffffffff6041557006c3390ecc8af379295fffffffffffffff60425570067c00a3b07ffc01fd6fffffffffffffff604355700637b647c39cbb9d3d27ffffffffffffff6044557005f63b1fc104dbd39587ffffffffffffff6045557005b771955b36e12f7235ffffffffffffff60465570057b3d49dda84556d6f6ffffffffffffff60475570054183095b2c8ececf30ffffffffffffff60485570050a28be635ca2b888f77fffffffffffff6049557004d5156639708c9db33c3fffffffffffff604a557004a23105873875bd52dfdfffffffffffff604b55700471649d87199aa990756fffffffffffff604c557004429a21a029d4c1457cfbffffffffffff604d55700415bc6d6fb7dd71af2cb3ffffffffffff604e557003eab73b3bbfe282243ce1ffffffffffff604f557003c1771ac9fb6b4c18e229ffffffffffff605055700399e96897690418f785257fffffffffff605155700373fc456c53bb779bf0ea9fffffffffff60525570034f9e8e490c48e67e6ab8bfffffffffff60535570032cbfd4a7adc790560b3337ffffffffff60545570030b50570f6e5d2acca94613ffffffffff6055557002eb40f9f620fda6b56c2861ffffffffff6056557002cc8340ecb0d0f520a6af58ffffffffff6057557002af09481380a0a35cf1ba02ffffffffff605855700292c5bdd3b92ec810287b1b3fffffffff605955700277abdcdab07d5a77ac6d6b9fffffffff605a5570025daf6654b1eaa55fd64df5efffffffff605b55700244c49c648baa98192dce88b7ffffffff605c5570022ce03cd5619a311b2471268bffffffff605d55700215f77c045fbe885654a44a0fffffffff605e557001ffffffffffffffffffffffffffffffff605f557001eaefdbdaaee7421fc4d3ede5ffffffff6060557001d6bd8b2eb257df7e8ca57b09bfffffff6061557001c35fedd14b861eb0443f7f133fffffff6062557001b0ce43b322bcde4a56e8ada5afffffff60635570019f0028ec1fff007f5a195a39dfffffff60645570018ded91f0e72ee74f49b15ba527ffffff60655570017d8ec7f04136f4e5615fd41a63ffffff60665570016ddc6556cdb84bdc8d12d22e6fffffff60675570015ecf52776a1155b5bd8395814f7fffff60685570015060c256cb23b3b3cc3754cf40ffffff6069557001428a2f98d728ae223ddab715be3fffff606a5570013545598e5c23276ccf0ede68034fffff606b557001288c4161ce1d6f54b7f61081194fffff606c5570011c592761c666aa641d5a01a40f17ffff606d55700110a688680a7530515f3e6e6cfdcdffff606e557001056f1b5bedf75c6bcb2ce8aed428ffff606f556ffaadceceeff8a0890f3875f008277fff6070556ff05dc6b27edad306388a600f6ba0bfff6071556fe67a5a25da41063de1495d5b18cdbfff6072556fdcff115b14eedde6fc3aa5353f2e4fff6073556fd3e7a3924312399f9aae2e0f868f8fff6074556fcb2ff529eb71e41582cccd5a1ee26fff6075556fc2d415c3db974ab32a51840c0b67edff6076556fbad03e7d883f69ad5b0a186184e06bff6077556fb320d03b2c343d4829abd6075f0cc5ff6078556fabc25204e02828d73c6e80bcdb1a95bf6079556fa4b16f74ee4bb2040a1ec6c15fbbf2df607a556f9deaf736ac1f569deb1b5ae3f36c130f607b556f976bd9952c7aa957f5937d790ef65037607c556f9131271922eaa6064b73a22d0bd4f2bf607d556f8b380f3558668c46c91c49a2f8e967b9607e556f857ddf0117efa215952912839f6473e66000607f5b0155565b6f60e393c68d20b1bd09deaabc0373b9c560809081556f5f8f46e4854120989ed94719fb4c20116081556f5e479ebb9129fb1b7e72a648f992b6066082556f5d0bd23fe42dfedde2e9586be12b85fe6083556f5bdb29ddee979308ddfca81aeeb8095a6084556f5ab4fd8a260d2c7e2c0d2afcf0009dad6085556f5998b31359a55d48724c65cf090012216086556f5885bcad2b322dfc43e8860f9c018cf56087556f577b97aa1fe222bb452fdf111b1f0be26088556f5679cb5e3575632e5baa27e2b949f7046089556f557fe8241b3a31c83c732f1cdff4a1c5608a556f548d868026504875d6e59bbe95fc2a6b608b556f53a2465ce347cf34d05a867c17dd3088608c556f52bdce5dcd4faed59c7f5511cf8f8acc608d556f51dfcb453c07f8da817606e7885f7c3e608e556f5107ef6b0a5a2be8f8ff15590daa3cce608f556f5035f241d6eae0cd7bacba119993de7b6090556f4f698fe90d5b53d532171e1210164c666091556f4ea288ca297a0e6a09a0eee240e16c856092556f4de0a13fdcf5d4213fc398ba6e3becde6093556f4d23a145eef91fec06b06140804c48086094556f4c6b5430d4c1ee5526473db4ae0f11de6095556f4bb7886c240562eba11f4963a53b42406096556f4b080f3f1cb491d2d521e0ea4583521e6097556f4a5cbc96a05589cb4d86be1db31683646098556f49b566d40243517658d78c33162d6ece6099556f4911e6a02e5507a30f947383fd9a3276609a556f487216c2b31be4adc41db8a8d5cc0c88609b556f47d5d3fc4a7a1b188cd3d788b5c5e9fc609c556f473cfce4871a2c40bc4f9e1c32b955d0609d556f46a771ca578ab878485810e285e31c67609e556f4615149718aed4c258c373dc676aa72d609f556f4585c8b3f8fe489c6e1833ca4787138460a0556f44f972f174e41e5efb7e9d63c29ce73560a1556f446ff970ba86d8b00beb05ecebf3c4dc60a2556f43e9438ec88971812d6f198b5ccaad9660a3556f436539d11ff7bea657aeddb394e809ef60a4556f42e3c5d3e5a913401d86f66db5d81c2c60a5556f4264d2395303070ea726cbe98df6217460a6556f41e84a9a593bb7194c3a6349ecae4eea60a7556f416e1b785d13eba07a08f3f18876a5ab60a8556f40f6322ff389d423ba9dd7e7e7b7e80960a9556f40807cec8a466880ecf4184545d240a460aa556f400cea9ce88a8d3ae668e8ea0d9bf07f60ab556f3f9b6ae8772d4c55091e0ed7dfea0ac160ac556f3f2bee253fd84594f54bcaafac383a1360ad556f3ebe654e95208bb9210c575c081c595860ae556f3e52c1fc5665635b78ce1f05ad53c08660af556f3de8f65ac388101ddf718a6f5c1eff6560b0556f3d80f522d59bd0b328ca012df4cd2d4960b1556f3d1ab193129ea72b23648a161163a85a60b2556f3cb61f68d32576c135b95cfb53f76d7560b3556f3c5332d9f1aae851a3619e77e4cc847360b4556f3bf1e08edbe2aa109e1525f65759ef7360b5556f3b921d9cff13fa2c197746a3dfc4918f60b6556f3b33df818910bfc1a5aefb8f63ae2ac460b7556f3ad71c1c77e34fa32a9f184967eccbf660b8556f3a7bc9abf2c5bb53e2f7384a8a16521a60b9556f3a21dec7e76369783a68a0c6385a1c5760ba556f39c9525de6c9cdf7c1c157ca4a7a6ee360bb556f39721bad3dc85d1240ff0190e0adaac360bc556f391c324344d3248f0469eb28dd3d77e060bd556f38c78df7e3c796279fb4ff84394ab3da60be556f387426ea4638ae9aae08049d3554c20a60bf556f3821f57dbd2763256c1a99bbd205137860c0556f37d0f256cb46a8c92ff62fbbef28969860c1556f37811658591ffc7abdd1feaf3cef9b7360c2556f37325aa10e9e82f7df0f380f7997154b60c3556f36e4b888cfb408d873b9a80d439311c660c4556f3698299e59f4bb9de645fc9b08c64cca60c5556f364ca7a5012cb603023b57dd3ebfd50d60c6556f36022c928915b778ab1b06aaee7e61d460c7556f35b8b28d1a73dc27500ffe35559cc02860c8556f357033e951fe250ec5eb4e60955132d760c9556f3528ab2867934e3a21b5412e4c4f888160ca556f34e212f66c55057f9676c80094a61d5960cb556f349c66289e5b3c4b540c24f42fa4b9bb60cc556f34579fbbd0c733a9c8d6af6b0f7d00f760cd556f3413bad2e712288b924b5882b5b369bf60ce556f33d0b2b56286510ef730e213f71f12e960cf556f338e82ce00e2496262c64457535ba1a160d0556f334d26a96b373bb7c2f8ea1827f27a9260d1556f330c99f4f4211469e00b3e18c31475ea60d2556f32ccd87d6486094999c7d5e6f33237d860d3556f328dde2dd617b6665a2e8556f250c1af60d4556f324fa70e9adc270f8262755af5a99af960d5556f32122f443110611ca51040f41fa6e1e360d6556f31d5730e42c0831482f0f1485c4263d860d7556f31996ec6b07b4a83421b5ebc4ab4e1f160d8556f315e1ee0a68ff46bb43ec2b85032e87660d9556f31237fe7bc4deacf6775b9efa1a145f860da556f30e98e7f1cc5a356e44627a6972ea2ff60db556f30b04760b8917ec74205a3002650ec0560dc556f3077a75c803468e9132ce0cf3224241d60dd556f303fab57a6a275c36f19cda9bace667a60de556f3008504beb8dcbd2cf3bc1f6d5a064f060df556f2fd19346ed17dac61219ce0c2c5ac4b060e0556f2f9b7169808c324b5852fd3d54ba971460e1556f2f65e7e711cf4b064eea9c08cbdad57460e2556f2f30f405093042ddff8a251b6bf6d10360e3556f2efc931a3750f2e8bfe323edfe03757460e4556f2ec8c28e46dbe56d98685278339400cb60e5556f2e957fd933c3926d8a599b602379b85160e6556f2e62c882c7c9ed4473412702f08ba0e560e7556f2e309a221c12ba361e3ed695167feee260e8556f2dfef25d1f865ae18dd07cfea4bcea1060e9556f2dcdcee821cdc80decc02c44344aeb3160ea556f2d9d2d8562b34944d0b201bb87260c8360eb556f2d6d0c04a5b62a2c42636308669b729a60ec556f2d3d6842c9a235517fc5a0332691528f60ed556f2d0e402963fe1ea2834abc408c437c1060ee556f2cdf91ae602647908aff975e4d6a2a8c60ef556f2cb15ad3a1eb65f6d74a75da09a1b6c560f0556f2c8399a6ab8e9774d6fcff373d21072760f1556f2c564c4046f64edba6883ca06bbc453560f2556f2c2970c431f952641e05cb493e23eed360f3556f2bfd0560cd9eb14563bc7c0732856c1860f4556f2bd1084ed0332f7ff4150f9d0ef41a2c60f5556f2ba577d0fa1628b76d040b12a82492fb60f6556f2b7a5233cd21581e855e89dc2f1e8a9260f7556f2b4f95cd46904d05d72bdcde337d9cc760f8556f2b2540fc9b4d9abba3faca669191467560f9556f2afb5229f68d0830d8be8adb0a0db70f60fa556f2ad1c7c63a9b294c5bc73a3ba3ab7a2b60fb556f2aa8a04ac3cbe1ee1c9c86361465dbb860fc556f2a7fda392d725a44a2c8aeb9ab35430d60fd556f2a57741b18cde618717792b4faa216db60fe556f2a2f6c81f5d84dd950a35626d6d5503a90607f611916565b6000808080806fd3094c70f034de4b96ff7d5b6f99fcd8861061236a576001607e1b840193506fd3094c70f034de4b96ff7d5b6f99fcd86001607f1b87028161236657fe5b0495505b6fa45af1e1f40c333b3de1db4dd55f29a786106123ad576001607d1b840193506fa45af1e1f40c333b3de1db4dd55f29a76001607f1b8702816123a957fe5b0495505b6f910b022db7ae67ce76b441c27035c6a186106123f0576001607c1b840193506f910b022db7ae67ce76b441c27035c6a16001607f1b8702816123ec57fe5b0495505b6f88415abbe9a76bead8d00cf112e4d4a88610612433576001607b1b840193506f88415abbe9a76bead8d00cf112e4d4a86001607f1b87028161242f57fe5b0495505b6f84102b00893f64c705e841d5d4064bd38610612476576001607a1b840193506f84102b00893f64c705e841d5d4064bd36001607f1b87028161247257fe5b0495505b6f8204055aaef1c8bd5c3259f4822735a286106124b957600160791b840193506f8204055aaef1c8bd5c3259f4822735a26001607f1b8702816124b557fe5b0495505b6f810100ab00222d861931c15e39b44e9986106124fc57600160781b840193506f810100ab00222d861931c15e39b44e996001607f1b8702816124f857fe5b0495505b6f808040155aabbbe9451521693554f733861061253f57600160771b840193506f808040155aabbbe9451521693554f7336001607f1b87028161253b57fe5b0495505b6f7fffffffffffffffffffffffffffffff19860192508291506001607f1b828002049050600160801b838103830204840193506001607f1b8183028161258157fe5b049150600160811b836faaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa038302816125a557fe5b04840193506001607f1b818302816125b957fe5b049150600360801b836f99999999999999999999999999999999038302816125dd57fe5b04840193506001607f1b818302816125f157fe5b049150600160821b836f924924924924924924924924924924920383028161261557fe5b04840193506001607f1b8183028161262957fe5b049150600560801b836f8e38e38e38e38e38e38e38e38e38e38e0383028161264d57fe5b04840193506001607f1b8183028161266157fe5b049150600360811b836f8ba2e8ba2e8ba2e8ba2e8ba2e8ba2e8b0383028161268557fe5b04840193506001607f1b8183028161269957fe5b049150600760801b836f89d89d89d89d89d89d89d89d89d89d89038302816126bd57fe5b04840193506001607f1b818302816126d157fe5b049150600160831b836f88888888888888888888888888888888038302816126f557fe5b049390930193505050505b919050565b600080600160801b83106127365760006127256001607f1b855b04613164565b60ff1693841c936001607f1b029150505b6001607f1b83111561278457607f5b60ff811615612782576001607f1b848002049350600160801b841061277957600193841c9360ff6000198301161b91909101905b60001901612745565b505b6f05b9de1d10bf4103d647b0955897ba806f03f80fe03f80fe03f80fe03f80fe03f88202049392505050565b6000670168244fdac780006001607f1b6f0fffffffffffffffffffffffffffffff84168080028290048082028390048083028490049485026710e1b3be415a00009092026705a0913f6b1e000091909102010192909181830204905080664807432bc1800002830192506001607f1b8282028161282957fe5b04905080660c0135dca0400002830192506001607f1b8282028161284957fe5b049050806601b707b1cdc00002830192506001607f1b8282028161286957fe5b049050806536e0f639b80002830192506001607f1b8282028161288857fe5b04905080650618fee9f80002830192506001607f1b828202816128a757fe5b04905080649c197dcc0002830192506001607f1b828202816128c557fe5b04905080640e30dce40002830192506001607f1b828202816128e357fe5b0490508064012ebd130002830192506001607f1b8282028161290157fe5b049050806317499f0002830192506001607f1b8282028161291e57fe5b049050806301a9d48002830192506001607f1b8282028161293b57fe5b04905080621c638002830192506001607f1b8282028161295757fe5b049050806201c63802830192506001607f1b8282028161297357fe5b04905080611ab802830192506001607f1b8282028161298e57fe5b0490508061017c02830192506001607f1b828202816129a957fe5b04905080601402830192506001607f1b828202816129c357fe5b6721c3677c82b400009190049384010482016001607f1b019290506001607c1b851615612a145770018ebef9eac820ae8682b9793ac6d1e7767001c3d6a24ed82218787d624d3e5eba95f984020492505b6001607d1b851615612a4a577001368b2fc6f9609fe7aceb46aa619baed470018ebef9eac820ae8682b9793ac6d1e77884020492505b6001607e1b851615612a7f576fbc5ab1b16779be3575bd8f0520a9f21f7001368b2fc6f9609fe7aceb46aa619baed584020492505b6001607f1b851615612ab3576f454aaa8efe072e7f6ddbab84b40a55c96fbc5ab1b16779be3575bd8f0520a9f21e84020492505b600160801b851615612ae7576f0960aadc109e7a3bf4578099615711ea6f454aaa8efe072e7f6ddbab84b40a55c584020492505b600160811b851615612b1a576e2bf84208204f5977f9a8cf01fdce3d6f0960aadc109e7a3bf4578099615711d784020492505b600160821b851615612b4b576d03c6ab775dd0b95b4cbee7e65d116e2bf84208204f5977f9a8cf01fdc30784020492505b50909392505050565b60006020607f5b8060ff168260010160ff161015612ba3576000600260ff848401160490508460008260ff1660808110612b8a57fe5b015410612b9957809250612b9d565b8091505b50612b5b565b8360008260ff1660808110612bb457fe5b015410612bc45791506127009050565b8360008360ff1660808110612bd557fe5b01541061011657509050612700565b60008083905060008360ff16858302901c9150816f03442c4e6074a82f1797f72ac000000002810190508360ff16858302901c9150816f0116b96f757c380fb287fd0e4000000002810190508360ff16858302901c9150816e45ae5bdd5f0e03eca1ff439000000002810190508360ff16858302901c9150816e0defabf91302cd95b9ffda5000000002810190508360ff16858302901c9150816e02529ca9832b22439efff9b800000002810190508360ff16858302901c9150816d54f1cf12bd04e516b6da8800000002810190508360ff16858302901c9150816d0a9e39e257a09ca2d6db5100000002810190508360ff16858302901c9150816d012e066e7b839fa050c30900000002810190508360ff16858302901c9150816c1e33d7d926c329a1ad1a80000002810190508360ff16858302901c9150816c02bee513bdb4a6b19b5f80000002810190508360ff16858302901c9150816b3a9316fa79b88eccf2a0000002810190508360ff16858302901c9150816b048177ebe1fa81237520000002810190508360ff16858302901c9150816a5263fe90242dcbacf0000002810190508360ff16858302901c9150816a057e22099c030d9410000002810190508360ff16858302901c9150816957e22099c030d941000002810190508360ff16858302901c91508169052b6b5456997631000002810190508360ff16858302901c915081684985f67696bf74800002810190508360ff16858302901c9150816803dea12ea99e49800002810190508360ff16858302901c9150816731880f2214b6e00002810190508360ff16858302901c91508167025bcff56eb3600002810190508360ff16858302901c915081661b722e10ab100002810190508360ff16858302901c9150816601317c7007700002810190508360ff16858302901c915081650cba84aafa0002810190508360ff16858302901c9150816482573a0a0002810190508360ff16858302901c9150816405035ad90002810190508360ff16858302901c915081632f881b0002810190508360ff16858302901c9150816301b2934002810190508360ff16858302901c915081620efc4002810190508360ff16858302901c915081617fe002810190508360ff16858302901c91508161042002810190508360ff16858302901c915081602102810190508360ff16858302901c915081600102810190508360ff166001901b856f0688589cc0e9505e2f2fee55800000008381612f7257fe5b04010195945050505050565b600080600160801b8411158015612f995750600160801b8311155b15612fa857508290508161113d565b600160801b841015612fd25782600160801b850281612fc357fe5b04600160801b9150915061113d565b600160801b831015612ffc57600160801b84600160801b850281612ff257fe5b049150915061113d565b600083851161300b578361300d565b845b9050600061301f6001607f1b8361271f565b60ff1695861c969490951c9450505050565b60006f2f16ac6c59de6f8d5d6f63c1482a7c86821161305a57613053826131c5565b9050612700565b81600160fe1b8161306757fe5b0492915050565b60006f2f16ac6c59de6f8d5d6f63c1482a7c8682116130905761305382613607565b7001af16ac6c59de6f8d5d6f63c1482a7c8082116130b15761305382613a67565b706b22d43e72c326539cceeef8bb48f255ff82116101165761305382613ae7565b6000807d10c6f7a0b5ed8d36b4c7f34938583621fafc8b0079a2834d26fa3fcc9ea98411156131395760017d10c6f7a0b5ed8d36b4c7f34938583621fafc8b0079a2834d26fa3fcc9eaa85040180858161312857fe5b04945080848161313457fe5b049350505b6000613153620f4240860261314e8787610f28565b613b70565b95620f424087900395509350505050565b60008061010083101561318c575b600183111561318757600192831c9201613172565b610f22565b60805b60ff8116156131be57600160ff82161b84106131b35760ff81169390931c92908117905b60011c607f1661318f565b5092915050565b600081816001607f1b82800204915070014d29a73a6e7b02c3668c7b08800000008202016001607f1b8483020491507002504a0cd9a7f7215b60f9be48000000008202016001607f1b848302049150700484d0a1191c0ead267967c7a4a00000008202016001607f1b84830204915070095ec580d7e8427a4baf26a90a000000008202016001607f1b848302049150701440b0be1615a47dba6e5b3b1f100000008202016001607f1b848302049150702d207601f46a99b41124184000000000008202016001607f1b8483020491507066ebaac4c37c622dd8288a7eb1b20000008202016001607f1b84830204915070ef17240135f7dbd43a1ba10cf2000000008202016001607f1b848302049150710233c33c676a5eb2416094a87b36570000008202016001607f1b848302049150710541cde48bc0254bed49a9f87000000000008202016001607f1b848302049150710cae1fad2cdd4d4cb8d73abca0d19a4000008202016001607f1b848302049150711edb2aa2f760d15c41ceedba9564000000008202016001607f1b848302049150714ba8d20d2dabd386c9529659841a2e2000008202016001607f1b8483020491506805d6042a35c33e6d51604d1b8202016001607f1b8483020491507201cfa8e70c03625b9db76c8ebf5bbf248200008202016001607f1b8483020491507204851d99f82060df265f3309b26f82000000008202016001607f1b848302049150720b550d19b129d270c44f6f55f027723cbb00008202016001607f1b848302049150721c877dadc761dc272deb65d4b00000000000008202016001607f1b8483020491507248178ece97479f33a77f2ad22a81b64406c0008202016001607f1b84830204915072b6ca8268b9d810fedf6695ef2f8a6c000000008202016001607f1b8483020491507301d0e76631a5b05d007b8cb72a7c7f11ec36e0008202016001607f1b84830204915069094386f7b3f0bfb38d8f604f1b8202016001607f1b848302049150730bd8369f1b702bf491e2ebfcee08250313b654008202016001607f1b848302049150731e5c7c32a9f6c70ab2cb59d9225764d4000000008202016001607f1b848302049150734dff5820e165e910f95120a708e742496221e6008202016001607f1b8483020491506c064647b36d8fe769bc7728729b603d1b8202016001607f1b848302049150740205db8dffff45bfa2938f128f599dbf16eb11d8808202016001607f1b84830204915074053a044ebd984351493e1786af38d39a08000000008202016001607f1b848302049150740d86dae2a4cc0f47633a544479735869b487b59c408202016001607f1b848302049150610231609c1b8202016001607f1b848302049150745b0485a76f6646c2039db1507cdd51b086496808228202016001607f1b84830204915074ec983c46c49545bc17efa6b5b0055e2422000000008202016001607f1b846fde1bc4d19efcac82445da75b0000000083040101949350505050565b6000816001607f1b8181036fde1bc4d19efcac82445da75b00000000029082800204915070014d29a73a6e7b02c3668c7b08800000008202016001607f1b8483020491507002504a0cd9a7f7215b60f9be4800000000820290036001607f1b848302049150700484d0a1191c0ead267967c7a4a00000008202016001607f1b84830204915070095ec580d7e8427a4baf26a90a00000000820290036001607f1b848302049150701440b0be1615a47dba6e5b3b1f100000008202016001607f1b848302049150702d207601f46a99b4112418400000000000820290036001607f1b8483020491507066ebaac4c37c622dd8288a7eb1b20000008202016001607f1b84830204915070ef17240135f7dbd43a1ba10cf200000000820290036001607f1b848302049150710233c33c676a5eb2416094a87b36570000008202016001607f1b848302049150710541cde48bc0254bed49a9f8700000000000820290036001607f1b848302049150710cae1fad2cdd4d4cb8d73abca0d19a4000008202016001607f1b848302049150711edb2aa2f760d15c41ceedba956400000000820290036001607f1b848302049150714ba8d20d2dabd386c9529659841a2e2000008202016001607f1b8483020491506805d6042a35c33e6d51604d1b820290036001607f1b8483020491507201cfa8e70c03625b9db76c8ebf5bbf248200008202016001607f1b8483020491507204851d99f82060df265f3309b26f8200000000820290036001607f1b848302049150720b550d19b129d270c44f6f55f027723cbb00008202016001607f1b848302049150721c877dadc761dc272deb65d4b0000000000000820290036001607f1b8483020491507248178ece97479f33a77f2ad22a81b64406c0008202016001607f1b84830204915072b6ca8268b9d810fedf6695ef2f8a6c00000000820290036001607f1b8483020491507301d0e76631a5b05d007b8cb72a7c7f11ec36e0008202016001607f1b84830204915069094386f7b3f0bfb38d8f604f1b820290036001607f1b848302049150730bd8369f1b702bf491e2ebfcee08250313b654008202016001607f1b848302049150731e5c7c32a9f6c70ab2cb59d9225764d400000000820290036001607f1b848302049150734dff5820e165e910f95120a708e742496221e6008202016001607f1b8483020491506c064647b36d8fe769bc7728729b603d1b820290036001607f1b848302049150740205db8dffff45bfa2938f128f599dbf16eb11d8808202016001607f1b84830204915074053a044ebd984351493e1786af38d39a0800000000820290036001607f1b848302049150740d86dae2a4cc0f47633a544479735869b487b59c408202016001607f1b848302049150610231609c1b820290036001607f1b848302049150745b0485a76f6646c2039db1507cdd51b086496808228202016001607f1b84830204915074ec983c46c49545bc17efa6b5b0055e242200000000820290036fde1bc4d19efcac82445da75b00000000815b04949350505050565b60006f2f16ac6c59de6f8d5d6f63c1482a7c861982016f03060c183060c183060c183060c183068082049081810290600183010284608084818110613aa857fe5b01549050600060808560010160808110613abe57fe5b01546f03060c183060c183060c183060c183069487030295909203029390930104949350505050565b60008070015bf0a8b1457695355fb8ac404e7a79e38310613b1057613b0b83612705565b613b19565b613b1983612321565b9050600070015bf0a8b1457695355fb8ac404e7a79e38210613b4357613b3e82612705565b613b4c565b613b4c82612321565b9050836001607f1b836001607f1b840281613b6357fe5b04838503010281613a5e57fe5b6000600282048203828481613b8157fe5b0681613b8957fe5b04828481613b9357fe5b0401939250505056fe4552525f494e56414c49445f524553455256455f42414c414e43450000000000a2646970667358221220d73468a9ed248ca029851e62b5a45ea7dacb44f19454ff40af5f79d9b61ce1f764736f6c634300060c0033",
+ "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106101165760003560e01c80638074590a116100a2578063abfd231d11610071578063abfd231d146101cc578063e1c7392a14610378578063ebbb215814610382578063f3250fe2146103b7578063f732f1c91461020157610116565b80638074590a146102a857806394491fab146102dd5780639d11410814610236578063a11aa1b41461031a57610116565b806348d73fed116100e957806348d73fed1461016257806349f9b0f71461020157806365098bb31461023657806376cf0b561461027357806379c1b4501461023657610116565b80631da6bbfb1461011b57806329a00e7c146101625780632f55bdb51461019757806335b49af4146101cc575b600080fd5b6101506004803603608081101561013157600080fd5b5080359060208101359063ffffffff60408201351690606001356103ec565b60408051918252519081900360200190f35b6101506004803603608081101561017857600080fd5b5080359060208101359063ffffffff6040820135169060600135610405565b610150600480360360808110156101ad57600080fd5b5080359060208101359063ffffffff6040820135169060600135610413565b610150600480360360808110156101e257600080fd5b5080359060208101359063ffffffff604082013516906060013561058b565b6101506004803603608081101561021757600080fd5b5080359060208101359063ffffffff6040820135169060600135610599565b610150600480360360a081101561024c57600080fd5b5080359063ffffffff602082013581169160408101359160608201351690608001356105a7565b6101506004803603608081101561028957600080fd5b5080359060208101359063ffffffff60408201351690606001356105c2565b610150600480360360808110156102be57600080fd5b5080359060208101359063ffffffff6040820135169060600135610788565b610150600480360360a08110156102f357600080fd5b5080359063ffffffff60208201358116916040810135916060820135169060800135610904565b61034f600480360360a081101561033057600080fd5b5080359060208101359060408101359060608101359060800135610a70565b604051808363ffffffff1681526020018263ffffffff1681526020019250505060405180910390f35b610380610bf8565b005b6101506004803603608081101561039857600080fd5b5080359060208101359063ffffffff6040820135169060600135610c0a565b610150600480360360808110156103cd57600080fd5b5080359060208101359063ffffffff6040820135169060600135610d8f565b60006103fa85858585610c0a565b90505b949350505050565b60006103fa85858585610d8f565b600080851161045e576040805162461bcd60e51b81526020600482015260126024820152714552525f494e56414c49445f535550504c5960701b604482015290519081900360640190fd5b600084116104a1576040805162461bcd60e51b815260206004820152601b6024820152600080516020613b9d833981519152604482015290519081900360640190fd5b60018363ffffffff161180156104c05750621e848063ffffffff841611155b61050d576040805162461bcd60e51b81526020600482015260196024820152784552525f494e56414c49445f524553455256455f524154494f60381b604482015290519081900360640190fd5b8161051a575060006103fd565b63ffffffff8316620f4240141561054557836105368387610ec1565b8161053d57fe5b0490506103fd565b600080806105538786610f28565b9050610564818888620f4240610f71565b9093509150600060ff83166105798a86610ec1565b901c9890980398975050505050505050565b60006103fa85858585610788565b60006103fa858585856105c2565b60006105b68686868686610904565b90505b95945050505050565b600080851161060d576040805162461bcd60e51b81526020600482015260126024820152714552525f494e56414c49445f535550504c5960701b604482015290519081900360640190fd5b60008411610650576040805162461bcd60e51b815260206004820152601b6024820152600080516020613b9d833981519152604482015290519081900360640190fd5b60008363ffffffff1611801561066f5750620f424063ffffffff841611155b6106bd576040805162461bcd60e51b815260206004820152601a60248201527911549497d253959053125117d49154d154959157d5d15251d21560321b604482015290519081900360640190fd5b84821115610707576040805162461bcd60e51b815260206004820152601260248201527111549497d253959053125117d05353d5539560721b604482015290519081900360640190fd5b81610714575060006103fd565b848214156107235750826103fd565b63ffffffff8316620f4240141561073f57846105368584610ec1565b6000808387036107548882620f424089610f71565b909350915060006107658885610ec1565b905060ff831688901b848183038161077957fe5b049a9950505050505050505050565b60008085116107d3576040805162461bcd60e51b81526020600482015260126024820152714552525f494e56414c49445f535550504c5960701b604482015290519081900360640190fd5b60008411610816576040805162461bcd60e51b815260206004820152601b6024820152600080516020613b9d833981519152604482015290519081900360640190fd5b60018363ffffffff161180156108355750621e848063ffffffff841611155b610882576040805162461bcd60e51b81526020600482015260196024820152784552525f494e56414c49445f524553455256455f524154494f60381b604482015290519081900360640190fd5b848211156108cc576040805162461bcd60e51b815260206004820152601260248201527111549497d253959053125117d05353d5539560721b604482015290519081900360640190fd5b816108d9575060006103fd565b848214156108e85750826103fd565b63ffffffff8316620f4240141561073f57846105368386610ec1565b600080861180156109155750600084115b610954576040805162461bcd60e51b815260206004820152601b6024820152600080516020613b9d833981519152604482015290519081900360640190fd5b60008563ffffffff161180156109735750620f424063ffffffff861611155b8015610985575060008363ffffffff16115b801561099a5750620f424063ffffffff841611155b6109e8576040805162461bcd60e51b815260206004820152601a60248201527911549497d253959053125117d49154d154959157d5d15251d21560321b604482015290519081900360640190fd5b8263ffffffff168563ffffffff161415610a1f57610a068683610f28565b610a108584610ec1565b81610a1757fe5b0490506105b9565b60008080610a2d8986610f28565b9050610a3b818a8a89610f71565b90935091506000610a4c8885610ec1565b905060ff831688901b8481830381610a6057fe5b049b9a5050505050505050505050565b60008085871415610ace576000871180610a8a5750600085115b610ac9576040805162461bcd60e51b815260206004820152601b6024820152600080516020613b9d833981519152604482015290519081900360640190fd5b610b29565b600087118015610ade5750600086115b8015610aea5750600085115b610b29576040805162461bcd60e51b815260206004820152601b6024820152600080516020613b9d833981519152604482015290519081900360640190fd5b600084118015610b395750600083115b610b8a576040805162461bcd60e51b815260206004820152601860248201527f4552525f494e56414c49445f524553455256455f524154450000000000000000604482015290519081900360640190fd5b6000610b968886610ec1565b90506000610ba48786610ec1565b905087891015610bc757610bbc888a84846001611043565b935093505050610bee565b87891115610bdd57610bbc898984846000611043565b610be7828261110c565b9350935050505b9550959350505050565b610c00611144565b610c0861191a565b565b6000808511610c55576040805162461bcd60e51b81526020600482015260126024820152714552525f494e56414c49445f535550504c5960701b604482015290519081900360640190fd5b60008411610c98576040805162461bcd60e51b815260206004820152601b6024820152600080516020613b9d833981519152604482015290519081900360640190fd5b60018363ffffffff16118015610cb75750621e848063ffffffff841611155b610d04576040805162461bcd60e51b81526020600482015260196024820152784552525f494e56414c49445f524553455256455f524154494f60381b604482015290519081900360640190fd5b81610d11575060006103fd565b63ffffffff8316620f42401415610d4257846001610d2f8487610ec1565b0381610d3757fe5b0460010190506103fd565b60008080610d508886610f28565b9050610d618189620f424089610f71565b9093509150600060ff83166001610d788a87610ec1565b03901c889003600101945050505050949350505050565b6000808511610dda576040805162461bcd60e51b81526020600482015260126024820152714552525f494e56414c49445f535550504c5960701b604482015290519081900360640190fd5b60008411610e1d576040805162461bcd60e51b815260206004820152601b6024820152600080516020613b9d833981519152604482015290519081900360640190fd5b60008363ffffffff16118015610e3c5750620f424063ffffffff841611155b610e8a576040805162461bcd60e51b815260206004820152601a60248201527911549497d253959053125117d49154d154959157d5d15251d21560321b604482015290519081900360640190fd5b81610e97575060006103fd565b63ffffffff8316620f42401415610eb357836105368684610ec1565b600080806105538588610f28565b600082610ed057506000610f22565b82820282848281610edd57fe5b0414610f1f576040805162461bcd60e51b815260206004820152600c60248201526b4552525f4f564552464c4f5760a01b604482015290519081900360640190fd5b90505b92915050565b600082820183811015610f1f576040805162461bcd60e51b815260206004820152600c60248201526b4552525f4f564552464c4f5760a01b604482015290519081900360640190fd5b600080600160811b8610610f8457600080fd5b600080866001607f1b890281610f9657fe5b04905070015bf0a8b1457695355fb8ac404e7a79e3811015610fc257610fbb81612321565b9150610fce565b610fcb81612705565b91505b60008563ffffffff168763ffffffff16840281610fe757fe5b049050600160831b81101561100d57610fff816127b0565b607f9450945050505061103a565b600061101882612b54565b905061102d81607f0360ff1683901c82612be4565b9550935061103a92505050565b94509492505050565b6000806110508585612f7e565b9095509350600086611066896001607f1b610ec1565b8161106d57fe5b049050600070015bf0a8b1457695355fb8ac404e7a79e382106110985761109382612705565b6110a1565b6110a182612321565b90506000866110b0838a610ec1565b816110b757fe5b0490506000866110cf576110ca82613031565b6110d8565b6110d88261306e565b90506110fa6110e7828b610ec1565b6110f58a6001607f1b610ec1565b61110c565b95509550505050509550959350505050565b6000808284116111295761112084846130d2565b9150915061113d565b60008061113685876130d2565b9450925050505b9250929050565b701c35fedd14ffffffffffffffffffffffff602055701b0ce43b323fffffffffffffffffffffff6021557019f0028ec1ffffffffffffffffffffffff6022557018ded91f0e7fffffffffffffffffffffff6023557017d8ec7f0417ffffffffffffffffffffff6024557016ddc6556cdbffffffffffffffffffffff6025557015ecf52776a1ffffffffffffffffffffff6026557015060c256cb2ffffffffffffffffffffff602755701428a2f98d72ffffffffffffffffffffff6028557013545598e5c23fffffffffffffffffffff602955701288c4161ce1dfffffffffffffffffffff602a557011c592761c666fffffffffffffffffffff602b5570110a688680a757ffffffffffffffffffff602c55701056f1b5bedf77ffffffffffffffffffff602d55700faadceceeff8bffffffffffffffffffff602e55700f05dc6b27edadffffffffffffffffffff602f55700e67a5a25da4107fffffffffffffffffff603055700dcff115b14eedffffffffffffffffffff603155700d3e7a392431239fffffffffffffffffff603255700cb2ff529eb71e4fffffffffffffffffff603355700c2d415c3db974afffffffffffffffffff603455700bad03e7d883f69bffffffffffffffffff603555700b320d03b2c343d5ffffffffffffffffff603655700abc25204e02828dffffffffffffffffff603755700a4b16f74ee4bb207fffffffffffffffff6038557009deaf736ac1f569ffffffffffffffffff603955700976bd9952c7aa957fffffffffffffffff603a557009131271922eaa606fffffffffffffffff603b557008b380f3558668c46fffffffffffffffff603c55700857ddf0117efa215bffffffffffffffff603d557007ffffffffffffffffffffffffffffffff603e557007abbf6f6abb9d087fffffffffffffffff603f5570075af62cbac95f7dfa7fffffffffffffff60405570070d7fb7452e187ac13fffffffffffffff6041557006c3390ecc8af379295fffffffffffffff60425570067c00a3b07ffc01fd6fffffffffffffff604355700637b647c39cbb9d3d27ffffffffffffff6044557005f63b1fc104dbd39587ffffffffffffff6045557005b771955b36e12f7235ffffffffffffff60465570057b3d49dda84556d6f6ffffffffffffff60475570054183095b2c8ececf30ffffffffffffff60485570050a28be635ca2b888f77fffffffffffff6049557004d5156639708c9db33c3fffffffffffff604a557004a23105873875bd52dfdfffffffffffff604b55700471649d87199aa990756fffffffffffff604c557004429a21a029d4c1457cfbffffffffffff604d55700415bc6d6fb7dd71af2cb3ffffffffffff604e557003eab73b3bbfe282243ce1ffffffffffff604f557003c1771ac9fb6b4c18e229ffffffffffff605055700399e96897690418f785257fffffffffff605155700373fc456c53bb779bf0ea9fffffffffff60525570034f9e8e490c48e67e6ab8bfffffffffff60535570032cbfd4a7adc790560b3337ffffffffff60545570030b50570f6e5d2acca94613ffffffffff6055557002eb40f9f620fda6b56c2861ffffffffff6056557002cc8340ecb0d0f520a6af58ffffffffff6057557002af09481380a0a35cf1ba02ffffffffff605855700292c5bdd3b92ec810287b1b3fffffffff605955700277abdcdab07d5a77ac6d6b9fffffffff605a5570025daf6654b1eaa55fd64df5efffffffff605b55700244c49c648baa98192dce88b7ffffffff605c5570022ce03cd5619a311b2471268bffffffff605d55700215f77c045fbe885654a44a0fffffffff605e557001ffffffffffffffffffffffffffffffff605f557001eaefdbdaaee7421fc4d3ede5ffffffff6060557001d6bd8b2eb257df7e8ca57b09bfffffff6061557001c35fedd14b861eb0443f7f133fffffff6062557001b0ce43b322bcde4a56e8ada5afffffff60635570019f0028ec1fff007f5a195a39dfffffff60645570018ded91f0e72ee74f49b15ba527ffffff60655570017d8ec7f04136f4e5615fd41a63ffffff60665570016ddc6556cdb84bdc8d12d22e6fffffff60675570015ecf52776a1155b5bd8395814f7fffff60685570015060c256cb23b3b3cc3754cf40ffffff6069557001428a2f98d728ae223ddab715be3fffff606a5570013545598e5c23276ccf0ede68034fffff606b557001288c4161ce1d6f54b7f61081194fffff606c5570011c592761c666aa641d5a01a40f17ffff606d55700110a688680a7530515f3e6e6cfdcdffff606e557001056f1b5bedf75c6bcb2ce8aed428ffff606f556ffaadceceeff8a0890f3875f008277fff6070556ff05dc6b27edad306388a600f6ba0bfff6071556fe67a5a25da41063de1495d5b18cdbfff6072556fdcff115b14eedde6fc3aa5353f2e4fff6073556fd3e7a3924312399f9aae2e0f868f8fff6074556fcb2ff529eb71e41582cccd5a1ee26fff6075556fc2d415c3db974ab32a51840c0b67edff6076556fbad03e7d883f69ad5b0a186184e06bff6077556fb320d03b2c343d4829abd6075f0cc5ff6078556fabc25204e02828d73c6e80bcdb1a95bf6079556fa4b16f74ee4bb2040a1ec6c15fbbf2df607a556f9deaf736ac1f569deb1b5ae3f36c130f607b556f976bd9952c7aa957f5937d790ef65037607c556f9131271922eaa6064b73a22d0bd4f2bf607d556f8b380f3558668c46c91c49a2f8e967b9607e556f857ddf0117efa215952912839f6473e66000607f5b0155565b6f60e393c68d20b1bd09deaabc0373b9c560809081556f5f8f46e4854120989ed94719fb4c20116081556f5e479ebb9129fb1b7e72a648f992b6066082556f5d0bd23fe42dfedde2e9586be12b85fe6083556f5bdb29ddee979308ddfca81aeeb8095a6084556f5ab4fd8a260d2c7e2c0d2afcf0009dad6085556f5998b31359a55d48724c65cf090012216086556f5885bcad2b322dfc43e8860f9c018cf56087556f577b97aa1fe222bb452fdf111b1f0be26088556f5679cb5e3575632e5baa27e2b949f7046089556f557fe8241b3a31c83c732f1cdff4a1c5608a556f548d868026504875d6e59bbe95fc2a6b608b556f53a2465ce347cf34d05a867c17dd3088608c556f52bdce5dcd4faed59c7f5511cf8f8acc608d556f51dfcb453c07f8da817606e7885f7c3e608e556f5107ef6b0a5a2be8f8ff15590daa3cce608f556f5035f241d6eae0cd7bacba119993de7b6090556f4f698fe90d5b53d532171e1210164c666091556f4ea288ca297a0e6a09a0eee240e16c856092556f4de0a13fdcf5d4213fc398ba6e3becde6093556f4d23a145eef91fec06b06140804c48086094556f4c6b5430d4c1ee5526473db4ae0f11de6095556f4bb7886c240562eba11f4963a53b42406096556f4b080f3f1cb491d2d521e0ea4583521e6097556f4a5cbc96a05589cb4d86be1db31683646098556f49b566d40243517658d78c33162d6ece6099556f4911e6a02e5507a30f947383fd9a3276609a556f487216c2b31be4adc41db8a8d5cc0c88609b556f47d5d3fc4a7a1b188cd3d788b5c5e9fc609c556f473cfce4871a2c40bc4f9e1c32b955d0609d556f46a771ca578ab878485810e285e31c67609e556f4615149718aed4c258c373dc676aa72d609f556f4585c8b3f8fe489c6e1833ca4787138460a0556f44f972f174e41e5efb7e9d63c29ce73560a1556f446ff970ba86d8b00beb05ecebf3c4dc60a2556f43e9438ec88971812d6f198b5ccaad9660a3556f436539d11ff7bea657aeddb394e809ef60a4556f42e3c5d3e5a913401d86f66db5d81c2c60a5556f4264d2395303070ea726cbe98df6217460a6556f41e84a9a593bb7194c3a6349ecae4eea60a7556f416e1b785d13eba07a08f3f18876a5ab60a8556f40f6322ff389d423ba9dd7e7e7b7e80960a9556f40807cec8a466880ecf4184545d240a460aa556f400cea9ce88a8d3ae668e8ea0d9bf07f60ab556f3f9b6ae8772d4c55091e0ed7dfea0ac160ac556f3f2bee253fd84594f54bcaafac383a1360ad556f3ebe654e95208bb9210c575c081c595860ae556f3e52c1fc5665635b78ce1f05ad53c08660af556f3de8f65ac388101ddf718a6f5c1eff6560b0556f3d80f522d59bd0b328ca012df4cd2d4960b1556f3d1ab193129ea72b23648a161163a85a60b2556f3cb61f68d32576c135b95cfb53f76d7560b3556f3c5332d9f1aae851a3619e77e4cc847360b4556f3bf1e08edbe2aa109e1525f65759ef7360b5556f3b921d9cff13fa2c197746a3dfc4918f60b6556f3b33df818910bfc1a5aefb8f63ae2ac460b7556f3ad71c1c77e34fa32a9f184967eccbf660b8556f3a7bc9abf2c5bb53e2f7384a8a16521a60b9556f3a21dec7e76369783a68a0c6385a1c5760ba556f39c9525de6c9cdf7c1c157ca4a7a6ee360bb556f39721bad3dc85d1240ff0190e0adaac360bc556f391c324344d3248f0469eb28dd3d77e060bd556f38c78df7e3c796279fb4ff84394ab3da60be556f387426ea4638ae9aae08049d3554c20a60bf556f3821f57dbd2763256c1a99bbd205137860c0556f37d0f256cb46a8c92ff62fbbef28969860c1556f37811658591ffc7abdd1feaf3cef9b7360c2556f37325aa10e9e82f7df0f380f7997154b60c3556f36e4b888cfb408d873b9a80d439311c660c4556f3698299e59f4bb9de645fc9b08c64cca60c5556f364ca7a5012cb603023b57dd3ebfd50d60c6556f36022c928915b778ab1b06aaee7e61d460c7556f35b8b28d1a73dc27500ffe35559cc02860c8556f357033e951fe250ec5eb4e60955132d760c9556f3528ab2867934e3a21b5412e4c4f888160ca556f34e212f66c55057f9676c80094a61d5960cb556f349c66289e5b3c4b540c24f42fa4b9bb60cc556f34579fbbd0c733a9c8d6af6b0f7d00f760cd556f3413bad2e712288b924b5882b5b369bf60ce556f33d0b2b56286510ef730e213f71f12e960cf556f338e82ce00e2496262c64457535ba1a160d0556f334d26a96b373bb7c2f8ea1827f27a9260d1556f330c99f4f4211469e00b3e18c31475ea60d2556f32ccd87d6486094999c7d5e6f33237d860d3556f328dde2dd617b6665a2e8556f250c1af60d4556f324fa70e9adc270f8262755af5a99af960d5556f32122f443110611ca51040f41fa6e1e360d6556f31d5730e42c0831482f0f1485c4263d860d7556f31996ec6b07b4a83421b5ebc4ab4e1f160d8556f315e1ee0a68ff46bb43ec2b85032e87660d9556f31237fe7bc4deacf6775b9efa1a145f860da556f30e98e7f1cc5a356e44627a6972ea2ff60db556f30b04760b8917ec74205a3002650ec0560dc556f3077a75c803468e9132ce0cf3224241d60dd556f303fab57a6a275c36f19cda9bace667a60de556f3008504beb8dcbd2cf3bc1f6d5a064f060df556f2fd19346ed17dac61219ce0c2c5ac4b060e0556f2f9b7169808c324b5852fd3d54ba971460e1556f2f65e7e711cf4b064eea9c08cbdad57460e2556f2f30f405093042ddff8a251b6bf6d10360e3556f2efc931a3750f2e8bfe323edfe03757460e4556f2ec8c28e46dbe56d98685278339400cb60e5556f2e957fd933c3926d8a599b602379b85160e6556f2e62c882c7c9ed4473412702f08ba0e560e7556f2e309a221c12ba361e3ed695167feee260e8556f2dfef25d1f865ae18dd07cfea4bcea1060e9556f2dcdcee821cdc80decc02c44344aeb3160ea556f2d9d2d8562b34944d0b201bb87260c8360eb556f2d6d0c04a5b62a2c42636308669b729a60ec556f2d3d6842c9a235517fc5a0332691528f60ed556f2d0e402963fe1ea2834abc408c437c1060ee556f2cdf91ae602647908aff975e4d6a2a8c60ef556f2cb15ad3a1eb65f6d74a75da09a1b6c560f0556f2c8399a6ab8e9774d6fcff373d21072760f1556f2c564c4046f64edba6883ca06bbc453560f2556f2c2970c431f952641e05cb493e23eed360f3556f2bfd0560cd9eb14563bc7c0732856c1860f4556f2bd1084ed0332f7ff4150f9d0ef41a2c60f5556f2ba577d0fa1628b76d040b12a82492fb60f6556f2b7a5233cd21581e855e89dc2f1e8a9260f7556f2b4f95cd46904d05d72bdcde337d9cc760f8556f2b2540fc9b4d9abba3faca669191467560f9556f2afb5229f68d0830d8be8adb0a0db70f60fa556f2ad1c7c63a9b294c5bc73a3ba3ab7a2b60fb556f2aa8a04ac3cbe1ee1c9c86361465dbb860fc556f2a7fda392d725a44a2c8aeb9ab35430d60fd556f2a57741b18cde618717792b4faa216db60fe556f2a2f6c81f5d84dd950a35626d6d5503a90607f611916565b6000808080806fd3094c70f034de4b96ff7d5b6f99fcd8861061236a576001607e1b840193506fd3094c70f034de4b96ff7d5b6f99fcd86001607f1b87028161236657fe5b0495505b6fa45af1e1f40c333b3de1db4dd55f29a786106123ad576001607d1b840193506fa45af1e1f40c333b3de1db4dd55f29a76001607f1b8702816123a957fe5b0495505b6f910b022db7ae67ce76b441c27035c6a186106123f0576001607c1b840193506f910b022db7ae67ce76b441c27035c6a16001607f1b8702816123ec57fe5b0495505b6f88415abbe9a76bead8d00cf112e4d4a88610612433576001607b1b840193506f88415abbe9a76bead8d00cf112e4d4a86001607f1b87028161242f57fe5b0495505b6f84102b00893f64c705e841d5d4064bd38610612476576001607a1b840193506f84102b00893f64c705e841d5d4064bd36001607f1b87028161247257fe5b0495505b6f8204055aaef1c8bd5c3259f4822735a286106124b957600160791b840193506f8204055aaef1c8bd5c3259f4822735a26001607f1b8702816124b557fe5b0495505b6f810100ab00222d861931c15e39b44e9986106124fc57600160781b840193506f810100ab00222d861931c15e39b44e996001607f1b8702816124f857fe5b0495505b6f808040155aabbbe9451521693554f733861061253f57600160771b840193506f808040155aabbbe9451521693554f7336001607f1b87028161253b57fe5b0495505b6f7fffffffffffffffffffffffffffffff19860192508291506001607f1b828002049050600160801b838103830204840193506001607f1b8183028161258157fe5b049150600160811b836faaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa038302816125a557fe5b04840193506001607f1b818302816125b957fe5b049150600360801b836f99999999999999999999999999999999038302816125dd57fe5b04840193506001607f1b818302816125f157fe5b049150600160821b836f924924924924924924924924924924920383028161261557fe5b04840193506001607f1b8183028161262957fe5b049150600560801b836f8e38e38e38e38e38e38e38e38e38e38e0383028161264d57fe5b04840193506001607f1b8183028161266157fe5b049150600360811b836f8ba2e8ba2e8ba2e8ba2e8ba2e8ba2e8b0383028161268557fe5b04840193506001607f1b8183028161269957fe5b049150600760801b836f89d89d89d89d89d89d89d89d89d89d89038302816126bd57fe5b04840193506001607f1b818302816126d157fe5b049150600160831b836f88888888888888888888888888888888038302816126f557fe5b049390930193505050505b919050565b600080600160801b83106127365760006127256001607f1b855b04613164565b60ff1693841c936001607f1b029150505b6001607f1b83111561278457607f5b60ff811615612782576001607f1b848002049350600160801b841061277957600193841c9360ff6000198301161b91909101905b60001901612745565b505b6f05b9de1d10bf4103d647b0955897ba806f03f80fe03f80fe03f80fe03f80fe03f88202049392505050565b6000670168244fdac780006001607f1b6f0fffffffffffffffffffffffffffffff84168080028290048082028390048083028490049485026710e1b3be415a00009092026705a0913f6b1e000091909102010192909181830204905080664807432bc1800002830192506001607f1b8282028161282957fe5b04905080660c0135dca0400002830192506001607f1b8282028161284957fe5b049050806601b707b1cdc00002830192506001607f1b8282028161286957fe5b049050806536e0f639b80002830192506001607f1b8282028161288857fe5b04905080650618fee9f80002830192506001607f1b828202816128a757fe5b04905080649c197dcc0002830192506001607f1b828202816128c557fe5b04905080640e30dce40002830192506001607f1b828202816128e357fe5b0490508064012ebd130002830192506001607f1b8282028161290157fe5b049050806317499f0002830192506001607f1b8282028161291e57fe5b049050806301a9d48002830192506001607f1b8282028161293b57fe5b04905080621c638002830192506001607f1b8282028161295757fe5b049050806201c63802830192506001607f1b8282028161297357fe5b04905080611ab802830192506001607f1b8282028161298e57fe5b0490508061017c02830192506001607f1b828202816129a957fe5b04905080601402830192506001607f1b828202816129c357fe5b6721c3677c82b400009190049384010482016001607f1b019290506001607c1b851615612a145770018ebef9eac820ae8682b9793ac6d1e7767001c3d6a24ed82218787d624d3e5eba95f984020492505b6001607d1b851615612a4a577001368b2fc6f9609fe7aceb46aa619baed470018ebef9eac820ae8682b9793ac6d1e77884020492505b6001607e1b851615612a7f576fbc5ab1b16779be3575bd8f0520a9f21f7001368b2fc6f9609fe7aceb46aa619baed584020492505b6001607f1b851615612ab3576f454aaa8efe072e7f6ddbab84b40a55c96fbc5ab1b16779be3575bd8f0520a9f21e84020492505b600160801b851615612ae7576f0960aadc109e7a3bf4578099615711ea6f454aaa8efe072e7f6ddbab84b40a55c584020492505b600160811b851615612b1a576e2bf84208204f5977f9a8cf01fdce3d6f0960aadc109e7a3bf4578099615711d784020492505b600160821b851615612b4b576d03c6ab775dd0b95b4cbee7e65d116e2bf84208204f5977f9a8cf01fdc30784020492505b50909392505050565b60006020607f5b8060ff168260010160ff161015612ba3576000600260ff848401160490508460008260ff1660808110612b8a57fe5b015410612b9957809250612b9d565b8091505b50612b5b565b8360008260ff1660808110612bb457fe5b015410612bc45791506127009050565b8360008360ff1660808110612bd557fe5b01541061011657509050612700565b60008083905060008360ff16858302901c9150816f03442c4e6074a82f1797f72ac000000002810190508360ff16858302901c9150816f0116b96f757c380fb287fd0e4000000002810190508360ff16858302901c9150816e45ae5bdd5f0e03eca1ff439000000002810190508360ff16858302901c9150816e0defabf91302cd95b9ffda5000000002810190508360ff16858302901c9150816e02529ca9832b22439efff9b800000002810190508360ff16858302901c9150816d54f1cf12bd04e516b6da8800000002810190508360ff16858302901c9150816d0a9e39e257a09ca2d6db5100000002810190508360ff16858302901c9150816d012e066e7b839fa050c30900000002810190508360ff16858302901c9150816c1e33d7d926c329a1ad1a80000002810190508360ff16858302901c9150816c02bee513bdb4a6b19b5f80000002810190508360ff16858302901c9150816b3a9316fa79b88eccf2a0000002810190508360ff16858302901c9150816b048177ebe1fa81237520000002810190508360ff16858302901c9150816a5263fe90242dcbacf0000002810190508360ff16858302901c9150816a057e22099c030d9410000002810190508360ff16858302901c9150816957e22099c030d941000002810190508360ff16858302901c91508169052b6b5456997631000002810190508360ff16858302901c915081684985f67696bf74800002810190508360ff16858302901c9150816803dea12ea99e49800002810190508360ff16858302901c9150816731880f2214b6e00002810190508360ff16858302901c91508167025bcff56eb3600002810190508360ff16858302901c915081661b722e10ab100002810190508360ff16858302901c9150816601317c7007700002810190508360ff16858302901c915081650cba84aafa0002810190508360ff16858302901c9150816482573a0a0002810190508360ff16858302901c9150816405035ad90002810190508360ff16858302901c915081632f881b0002810190508360ff16858302901c9150816301b2934002810190508360ff16858302901c915081620efc4002810190508360ff16858302901c915081617fe002810190508360ff16858302901c91508161042002810190508360ff16858302901c915081602102810190508360ff16858302901c915081600102810190508360ff166001901b856f0688589cc0e9505e2f2fee55800000008381612f7257fe5b04010195945050505050565b600080600160801b8411158015612f995750600160801b8311155b15612fa857508290508161113d565b600160801b841015612fd25782600160801b850281612fc357fe5b04600160801b9150915061113d565b600160801b831015612ffc57600160801b84600160801b850281612ff257fe5b049150915061113d565b600083851161300b578361300d565b845b9050600061301f6001607f1b8361271f565b60ff1695861c969490951c9450505050565b60006f2f16ac6c59de6f8d5d6f63c1482a7c86821161305a57613053826131c5565b9050612700565b81600160fe1b8161306757fe5b0492915050565b60006f2f16ac6c59de6f8d5d6f63c1482a7c8682116130905761305382613607565b7001af16ac6c59de6f8d5d6f63c1482a7c8082116130b15761305382613a67565b706b22d43e72c326539cceeef8bb48f255ff82116101165761305382613ae7565b6000807d10c6f7a0b5ed8d36b4c7f34938583621fafc8b0079a2834d26fa3fcc9ea98411156131395760017d10c6f7a0b5ed8d36b4c7f34938583621fafc8b0079a2834d26fa3fcc9eaa85040180858161312857fe5b04945080848161313457fe5b049350505b6000613153620f4240860261314e8787610f28565b613b70565b95620f424087900395509350505050565b60008061010083101561318c575b600183111561318757600192831c9201613172565b610f22565b60805b60ff8116156131be57600160ff82161b84106131b35760ff81169390931c92908117905b60011c607f1661318f565b5092915050565b600081816001607f1b82800204915070014d29a73a6e7b02c3668c7b08800000008202016001607f1b8483020491507002504a0cd9a7f7215b60f9be48000000008202016001607f1b848302049150700484d0a1191c0ead267967c7a4a00000008202016001607f1b84830204915070095ec580d7e8427a4baf26a90a000000008202016001607f1b848302049150701440b0be1615a47dba6e5b3b1f100000008202016001607f1b848302049150702d207601f46a99b41124184000000000008202016001607f1b8483020491507066ebaac4c37c622dd8288a7eb1b20000008202016001607f1b84830204915070ef17240135f7dbd43a1ba10cf2000000008202016001607f1b848302049150710233c33c676a5eb2416094a87b36570000008202016001607f1b848302049150710541cde48bc0254bed49a9f87000000000008202016001607f1b848302049150710cae1fad2cdd4d4cb8d73abca0d19a4000008202016001607f1b848302049150711edb2aa2f760d15c41ceedba9564000000008202016001607f1b848302049150714ba8d20d2dabd386c9529659841a2e2000008202016001607f1b8483020491506805d6042a35c33e6d51604d1b8202016001607f1b8483020491507201cfa8e70c03625b9db76c8ebf5bbf248200008202016001607f1b8483020491507204851d99f82060df265f3309b26f82000000008202016001607f1b848302049150720b550d19b129d270c44f6f55f027723cbb00008202016001607f1b848302049150721c877dadc761dc272deb65d4b00000000000008202016001607f1b8483020491507248178ece97479f33a77f2ad22a81b64406c0008202016001607f1b84830204915072b6ca8268b9d810fedf6695ef2f8a6c000000008202016001607f1b8483020491507301d0e76631a5b05d007b8cb72a7c7f11ec36e0008202016001607f1b84830204915069094386f7b3f0bfb38d8f604f1b8202016001607f1b848302049150730bd8369f1b702bf491e2ebfcee08250313b654008202016001607f1b848302049150731e5c7c32a9f6c70ab2cb59d9225764d4000000008202016001607f1b848302049150734dff5820e165e910f95120a708e742496221e6008202016001607f1b8483020491506c064647b36d8fe769bc7728729b603d1b8202016001607f1b848302049150740205db8dffff45bfa2938f128f599dbf16eb11d8808202016001607f1b84830204915074053a044ebd984351493e1786af38d39a08000000008202016001607f1b848302049150740d86dae2a4cc0f47633a544479735869b487b59c408202016001607f1b848302049150610231609c1b8202016001607f1b848302049150745b0485a76f6646c2039db1507cdd51b086496808228202016001607f1b84830204915074ec983c46c49545bc17efa6b5b0055e2422000000008202016001607f1b846fde1bc4d19efcac82445da75b0000000083040101949350505050565b6000816001607f1b8181036fde1bc4d19efcac82445da75b00000000029082800204915070014d29a73a6e7b02c3668c7b08800000008202016001607f1b8483020491507002504a0cd9a7f7215b60f9be4800000000820290036001607f1b848302049150700484d0a1191c0ead267967c7a4a00000008202016001607f1b84830204915070095ec580d7e8427a4baf26a90a00000000820290036001607f1b848302049150701440b0be1615a47dba6e5b3b1f100000008202016001607f1b848302049150702d207601f46a99b4112418400000000000820290036001607f1b8483020491507066ebaac4c37c622dd8288a7eb1b20000008202016001607f1b84830204915070ef17240135f7dbd43a1ba10cf200000000820290036001607f1b848302049150710233c33c676a5eb2416094a87b36570000008202016001607f1b848302049150710541cde48bc0254bed49a9f8700000000000820290036001607f1b848302049150710cae1fad2cdd4d4cb8d73abca0d19a4000008202016001607f1b848302049150711edb2aa2f760d15c41ceedba956400000000820290036001607f1b848302049150714ba8d20d2dabd386c9529659841a2e2000008202016001607f1b8483020491506805d6042a35c33e6d51604d1b820290036001607f1b8483020491507201cfa8e70c03625b9db76c8ebf5bbf248200008202016001607f1b8483020491507204851d99f82060df265f3309b26f8200000000820290036001607f1b848302049150720b550d19b129d270c44f6f55f027723cbb00008202016001607f1b848302049150721c877dadc761dc272deb65d4b0000000000000820290036001607f1b8483020491507248178ece97479f33a77f2ad22a81b64406c0008202016001607f1b84830204915072b6ca8268b9d810fedf6695ef2f8a6c00000000820290036001607f1b8483020491507301d0e76631a5b05d007b8cb72a7c7f11ec36e0008202016001607f1b84830204915069094386f7b3f0bfb38d8f604f1b820290036001607f1b848302049150730bd8369f1b702bf491e2ebfcee08250313b654008202016001607f1b848302049150731e5c7c32a9f6c70ab2cb59d9225764d400000000820290036001607f1b848302049150734dff5820e165e910f95120a708e742496221e6008202016001607f1b8483020491506c064647b36d8fe769bc7728729b603d1b820290036001607f1b848302049150740205db8dffff45bfa2938f128f599dbf16eb11d8808202016001607f1b84830204915074053a044ebd984351493e1786af38d39a0800000000820290036001607f1b848302049150740d86dae2a4cc0f47633a544479735869b487b59c408202016001607f1b848302049150610231609c1b820290036001607f1b848302049150745b0485a76f6646c2039db1507cdd51b086496808228202016001607f1b84830204915074ec983c46c49545bc17efa6b5b0055e242200000000820290036fde1bc4d19efcac82445da75b00000000815b04949350505050565b60006f2f16ac6c59de6f8d5d6f63c1482a7c861982016f03060c183060c183060c183060c183068082049081810290600183010284608084818110613aa857fe5b01549050600060808560010160808110613abe57fe5b01546f03060c183060c183060c183060c183069487030295909203029390930104949350505050565b60008070015bf0a8b1457695355fb8ac404e7a79e38310613b1057613b0b83612705565b613b19565b613b1983612321565b9050600070015bf0a8b1457695355fb8ac404e7a79e38210613b4357613b3e82612705565b613b4c565b613b4c82612321565b9050836001607f1b836001607f1b840281613b6357fe5b04838503010281613a5e57fe5b6000600282048203828481613b8157fe5b0681613b8957fe5b04828481613b9357fe5b0401939250505056fe4552525f494e56414c49445f524553455256455f42414c414e43450000000000a2646970667358221220d73468a9ed248ca029851e62b5a45ea7dacb44f19454ff40af5f79d9b61ce1f764736f6c634300060c0033",
+ "immutableReferences": {},
+ "sourceMap": "157:69425:7:-:0;;;;;;;;;;;;;;;;;;;",
+ "deployedSourceMap": "157:69425:7:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;66935:355;;;;;;;;;;;;;;;;-1:-1:-1;66935:355:7;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;64717:399;;;;;;;;;;;;;;;;-1:-1:-1;64717:399:7;;;;;;;;;;;;;;;;;;;:::i;27312:1068::-;;;;;;;;;;;;;;;;-1:-1:-1;27312:1068:7;;;;;;;;;;;;;;;;;;;:::i;69230:349::-;;;;;;;;;;;;;;;;-1:-1:-1;69230:349:7;;;;;;;;;;;;;;;;;;;:::i;65190:375::-;;;;;;;;;;;;;;;;-1:-1:-1;65190:375:7;;;;;;;;;;;;;;;;;;;:::i;66281:580::-;;;;;;;;;;;;;;;;-1:-1:-1;66281:580:7;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;21415:1297::-;;;;;;;;;;;;;;;;-1:-1:-1;21415:1297:7;;;;;;;;;;;;;;;;;;;:::i;29062:1331::-;;;;;;;;;;;;;;;;-1:-1:-1;29062:1331:7;;;;;;;;;;;;;;;;;;;:::i;23568:::-;;;;;;;;;;;;;;;;-1:-1:-1;23568:1331:7;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;32724:1425::-;;;;;;;;;;;;;;;;-1:-1:-1;32724:1425:7;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;18929:88;;;:::i;:::-;;25578:1050;;;;;;;;;;;;;;;;-1:-1:-1;25578:1050:7;;;;;;;;;;;;;;;;;;;:::i;19672:1091::-;;;;;;;;;;;;;;;;-1:-1:-1;19672:1091:7;;;;;;;;;;;;;;;;;;;:::i;66935:355::-;67192:7;67224:58;67233:7;67242:15;67259:13;67274:7;67224:8;:58::i;:::-;67217:65;;66935:355;;;;;;;:::o;64717:399::-;65005:7;65037:71;65058:7;65067:15;65084:14;65100:7;65037:20;:71::i;27312:1068::-;27573:7;27643:1;27633:7;:11;27625:42;;;;;-1:-1:-1;;;27625:42:7;;;;;;;;;;;;-1:-1:-1;;;27625:42:7;;;;;;;;;;;;;;;27704:1;27686:15;:19;27678:59;;;;;-1:-1:-1;;;27678:59:7;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;27678:59:7;;;;;;;;;;;;;;;27772:1;27756:13;:17;;;:52;;;;-1:-1:-1;27794:14:7;27777:31;;;;;27756:52;27748:90;;;;;-1:-1:-1;;;27748:90:7;;;;;;;;;;;;-1:-1:-1;;;27748:90:7;;;;;;;;;;;;;;;27893:12;27889:39;;-1:-1:-1;27927:1:7;27920:8;;27889:39;27998:27;;;316:7;27998:27;27994:91;;;28070:15;28047:20;:7;28059;28047:11;:20::i;:::-;:38;;;;;;28040:45;;;;27994:91;28098:14;;;28165:28;:15;28185:7;28165:19;:28::i;:::-;28149:44;;28226:56;28232:5;28239:15;28256:13;316:7;28226:5;:56::i;:::-;28204:78;;-1:-1:-1;28204:78:7;-1:-1:-1;28293:12:7;28308:32;;;:19;:7;28204:78;28308:11;:19::i;:::-;:32;;28358:14;;;;;27312:1068;-1:-1:-1;;;;;;;;27312:1068:7:o;69230:349::-;69467:7;69499:72;69522:7;69531:15;69548:13;69563:7;69499:22;:72::i;65190:375::-;65458:7;65490:67;65507:7;65516:15;65533:14;65549:7;65490:16;:67::i;66281:580::-;66698:7;66730:123;66755:21;66778:20;66800:21;66823:20;66845:7;66730:24;:123::i;:::-;66723:130;;66281:580;;;;;;;;:::o;21415:1297::-;21677:7;21747:1;21737:7;:11;21729:42;;;;;-1:-1:-1;;;21729:42:7;;;;;;;;;;;;-1:-1:-1;;;21729:42:7;;;;;;;;;;;;;;;21808:1;21790:15;:19;21782:59;;;;;-1:-1:-1;;;21782:59:7;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;21782:59:7;;;;;;;;;;;;;;;21877:1;21860:14;:18;;;:50;;;;-1:-1:-1;316:7:7;21882:28;;;;;21860:50;21852:89;;;;;-1:-1:-1;;;21852:89:7;;;;;;;;;;;;-1:-1:-1;;;21852:89:7;;;;;;;;;;;;;;;21971:7;21960;:18;;21952:49;;;;;-1:-1:-1;;;21952:49:7;;;;;;;;;;;;-1:-1:-1;;;21952:49:7;;;;;;;;;;;;;;;22061:12;22057:39;;-1:-1:-1;22095:1:7;22088:8;;22057:39;22179:7;22168;:18;22164:59;;;-1:-1:-1;22208:15:7;22201:22;;22164:59;22286:28;;;316:7;22286:28;22282:92;;;22367:7;22336:28;:15;22356:7;22336:19;:28::i;22282:92::-;22387:14;;22454:17;;;22504:49;22454:7;:17;316:7;22538:14;22504:5;:49::i;:::-;22482:71;;-1:-1:-1;22482:71:7;-1:-1:-1;22564:13:7;22580:27;:15;22482:71;22580:19;:27::i;:::-;22564:43;-1:-1:-1;22634:28:7;;;;;;22698:6;22681:13;;;22698:6;22680:24;;;;;;21415:1297;-1:-1:-1;;;;;;;;;;21415:1297:7:o;29062:1331::-;29353:7;29423:1;29413:7;:11;29405:42;;;;;-1:-1:-1;;;29405:42:7;;;;;;;;;;;;-1:-1:-1;;;29405:42:7;;;;;;;;;;;;;;;29484:1;29466:15;:19;29458:59;;;;;-1:-1:-1;;;29458:59:7;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;29458:59:7;;;;;;;;;;;;;;;29552:1;29536:13;:17;;;:52;;;;-1:-1:-1;29574:14:7;29557:31;;;;;29536:52;29528:90;;;;;-1:-1:-1;;;29528:90:7;;;;;;;;;;;;-1:-1:-1;;;29528:90:7;;;;;;;;;;;;;;;29648:7;29637;:18;;29629:49;;;;;-1:-1:-1;;;29629:49:7;;;;;;;;;;;;-1:-1:-1;;;29629:49:7;;;;;;;;;;;;;;;29733:12;29729:39;;-1:-1:-1;29767:1:7;29760:8;;29729:39;29855:7;29844;:18;29840:59;;;-1:-1:-1;29884:15:7;29877:22;;29840:59;29969:27;;;316:7;29969:27;29965:91;;;30049:7;30018:28;:7;30030:15;30018:11;:28::i;23568:1331::-;23964:7;24048:1;24024:21;:25;:54;;;;;24077:1;24053:21;:25;24024:54;24016:94;;;;;-1:-1:-1;;;24016:94:7;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;24016:94:7;;;;;;;;;;;;;;;24152:1;24129:20;:24;;;:62;;;;-1:-1:-1;316:7:7;24157:34;;;;;24129:62;:107;;;;;24235:1;24212:20;:24;;;24129:107;:145;;;;-1:-1:-1;316:7:7;24240:34;;;;;24129:145;24121:184;;;;;-1:-1:-1;;;24121:184:7;;;;;;;;;;;;-1:-1:-1;;;24121:184:7;;;;;;;;;;;;;;;24389:20;24365:44;;:20;:44;;;24361:141;;;24468:34;:21;24494:7;24468:25;:34::i;:::-;24431;:21;24457:7;24431:25;:34::i;:::-;:71;;;;;;24424:78;;;;24361:141;24515:14;;;24582:34;:21;24608:7;24582:25;:34::i;:::-;24566:50;;24649:79;24655:5;24662:21;24685:20;24707;24649:5;:79::i;:::-;24627:101;;-1:-1:-1;24627:101:7;-1:-1:-1;24739:13:7;24755:33;:21;24627:101;24755:25;:33::i;:::-;24739:49;-1:-1:-1;24815:34:7;;;;;;24885:6;24868:13;;;24885:6;24867:24;;;;;;23568:1331;-1:-1:-1;;;;;;;;;;;23568:1331:7:o;32724:1425::-;33097:6;33105;33165:22;33133:28;:54;33129:340;;;33241:1;33210:28;:32;:64;;;;33273:1;33246:24;:28;33210:64;33202:104;;;;;-1:-1:-1;;;33202:104:7;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;33202:104:7;;;;;;;;;;;;;;;33129:340;;;33374:1;33343:28;:32;:62;;;;;33404:1;33379:22;:26;33343:62;:94;;;;;33436:1;33409:24;:28;33343:94;33335:134;;;;;-1:-1:-1;;;33335:134:7;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;33335:134:7;;;;;;;;;;;;;;;33512:1;33488:21;:25;:56;;;;;33543:1;33517:23;:27;33488:56;33480:93;;;;;-1:-1:-1;;;33480:93:7;;;;;;;;;;;;;;;;;;;;;;;;;;;;33586:10;33599:55;:28;33632:21;33599:32;:55::i;:::-;33586:68;-1:-1:-1;33665:10:7;33678:53;:24;33707:23;33678:28;:53::i;:::-;33665:66;;33779:22;33748:28;:53;33744:169;;;33823:90;33846:22;33870:28;33900:2;33904;33908:4;33823:22;:90::i;:::-;33816:97;;;;;;;;33744:169;33961:22;33930:28;:53;33926:170;;;34005:91;34028:28;34058:22;34082:2;34086;34090:5;34005:22;:91::i;33926:170::-;34116:25;34134:2;34138;34116:17;:25::i;:::-;34109:32;;;;;;32724:1425;;;;;;;;;:::o;18929:88::-;18963:17;:15;:17::i;:::-;18991:18;:16;:18::i;:::-;18929:88::o;25578:1050::-;25799:7;25869:1;25859:7;:11;25851:42;;;;;-1:-1:-1;;;25851:42:7;;;;;;;;;;;;-1:-1:-1;;;25851:42:7;;;;;;;;;;;;;;;25930:1;25912:15;:19;25904:59;;;;;-1:-1:-1;;;25904:59:7;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;25904:59:7;;;;;;;;;;;;;;;25998:1;25982:13;:17;;;:52;;;;-1:-1:-1;26020:14:7;26003:31;;;;;25982:52;25974:90;;;;;-1:-1:-1;;;25974:90:7;;;;;;;;;;;;-1:-1:-1;;;25974:90:7;;;;;;;;;;;;;;;26119:12;26115:39;;-1:-1:-1;26153:1:7;26146:8;;26115:39;26224:27;;;316:7;26224:27;26220:101;;;26310:7;26305:1;26274:28;:7;26286:15;26274:11;:28::i;:::-;:32;26273:44;;;;;;26320:1;26273:48;26266:55;;;;26220:101;26334:14;;;26401:20;:7;26413;26401:11;:20::i;:::-;26385:36;;26454:48;26460:5;26467:7;316;26488:13;26454:5;:48::i;:::-;26432:70;;-1:-1:-1;26432:70:7;-1:-1:-1;26513:12:7;26529:46;;;26560:1;26530:27;:15;26432:70;26530:19;:27::i;:::-;:31;26529:46;;26598:22;;;26579:1;26598:22;;-1:-1:-1;;;;;25578:1050:7;;;;;;:::o;19672:1091::-;19954:7;20024:1;20014:7;:11;20006:42;;;;;-1:-1:-1;;;20006:42:7;;;;;;;;;;;;-1:-1:-1;;;20006:42:7;;;;;;;;;;;;;;;20085:1;20067:15;:19;20059:59;;;;;-1:-1:-1;;;20059:59:7;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;20059:59:7;;;;;;;;;;;;;;;20154:1;20137:14;:18;;;:50;;;;-1:-1:-1;316:7:7;20159:28;;;;;20137:50;20129:89;;;;;-1:-1:-1;;;20129:89:7;;;;;;;;;;;;-1:-1:-1;;;20129:89:7;;;;;;;;;;;;;;;20281:12;20277:39;;-1:-1:-1;20315:1:7;20308:8;;20277:39;20379:28;;;316:7;20379:28;20375:92;;;20452:15;20429:20;:7;20441;20429:11;:20::i;20375:92::-;20480:14;;;20547:28;:7;20559:15;20547:11;:28::i;1149:250:60:-;1209:7;1262;1258:34;;-1:-1:-1;1291:1:60;1284:8;;1258:34;1317:7;;;1322:2;1317;:7;:2;1343:6;;;;;:12;1335:37;;;;;-1:-1:-1;;;1335:37:60;;;;;;;;;;;;-1:-1:-1;;;1335:37:60;;;;;;;;;;;;;;;1390:1;-1:-1:-1;1149:250:60;;;;;:::o;386:169::-;446:7;478;;;504;;;;496:32;;;;;-1:-1:-1;;;496:32:60;;;;;;;;;;;;-1:-1:-1;;;496:32:60;;;;;;;;;;;;;;35739:791:7;35837:7;35846:5;-1:-1:-1;;;35872:6:7;:16;35864:25;;;;;;35902:15;35928:12;35962:6;-1:-1:-1;;;35943:6:7;:16;:25;;;;;;35928:40;;1072:35;35983:4;:22;35979:149;;;36032:16;36043:4;36032:10;:16::i;:::-;36022:26;;35979:149;;;36100:16;36111:4;36100:10;:16::i;:::-;36090:26;;35979:149;36140:23;36184:5;36166:23;;36176:5;36166:15;;:7;:15;:23;;;;;;36140:49;;-1:-1:-1;;;36204:15:7;:33;36200:323;;;36262:27;36273:15;36262:10;:27::i;:::-;417:3;36254:51;;;;;;;;;36200:323;36347:15;36365:42;36391:15;36365:25;:42::i;:::-;36347:60;;36430:69;36477:9;417:3;36461:25;36441:46;;:15;:46;;36489:9;36430:10;:69::i;:::-;36422:89;-1:-1:-1;36501:9:7;-1:-1:-1;36422:89:7;;-1:-1:-1;;;36422:89:7;35739:791;;;;;;;;:::o;62502:484::-;62627:6;62635;62667:21;62679:3;62684;62667:11;:21::i;:::-;62654:34;;-1:-1:-1;62654:34:7;-1:-1:-1;62699:9:7;62730:3;62711:16;:3;-1:-1:-1;;;62711:7:7;:16::i;:::-;:22;;;;;;62699:34;;62744:9;1072:35;62756:1;:19;:51;;62794:13;62805:1;62794:10;:13::i;:::-;62756:51;;;62778:13;62789:1;62778:10;:13::i;:::-;62744:63;-1:-1:-1;62818:9:7;62843:3;62830:10;62744:63;62836:3;62830:5;:10::i;:::-;:16;;;;;;62818:28;;62857:9;62869:11;:44;;62899:14;62911:1;62899:11;:14::i;:::-;62869:44;;;62883:13;62894:1;62883:10;:13::i;:::-;62857:56;-1:-1:-1;62931:47:7;62949:10;62857:56;62955:3;62949:5;:10::i;:::-;62961:16;:3;-1:-1:-1;;;62961:7:7;:16::i;:::-;62931:17;:47::i;:::-;62924:54;;;;;;;;62502:484;;;;;;;;:::o;63627:247::-;63701:6;63709;63738:2;63732;:8;63728:57;;63762:23;63778:2;63782;63762:15;:23::i;:::-;63755:30;;;;;;63728:57;63797:8;63807;63819:23;63835:2;63839;63819:15;:23::i;:::-;63796:46;-1:-1:-1;63796:46:7;-1:-1:-1;;;63627:247:7;;;;;;:::o;1867:8491::-;4044:36;4038:2;4025:55;4110:36;4104:2;4091:55;4176:36;4170:2;4157:55;4242:36;4236:2;4223:55;4308:36;4302:2;4289:55;4374:36;4368:2;4355:55;4440:36;4434:2;4421:55;4506:36;4500:2;4487:55;4572:36;4566:2;4553:55;4638:36;4632:2;4619:55;4704:36;4698:2;4685:55;4770:36;4764:2;4751:55;4836:36;4830:2;4817:55;4902:36;4896:2;4883:55;4968:36;4962:2;4949:55;5034:36;5028:2;5015:55;5100:36;5094:2;5081:55;5166:36;5160:2;5147:55;5232:36;5226:2;5213:55;5298:36;5292:2;5279:55;5364:36;5358:2;5345:55;5430:36;5424:2;5411:55;5496:36;5490:2;5477:55;5562:36;5556:2;5543:55;5628:36;5622:2;5609:55;5694:36;5688:2;5675:55;5760:36;5754:2;5741:55;5826:36;5820:2;5807:55;5892:36;5886:2;5873:55;5958:36;5952:2;5939:55;6024:36;6018:2;6005:55;6090:36;6084:2;6071:55;6156:36;6150:2;6137:55;6222:36;6216:2;6203:55;6288:36;6282:2;6269:55;6354:36;6348:2;6335:55;6420:36;6414:2;6401:55;6486:36;6480:2;6467:55;6552:36;6546:2;6533:55;6618:36;6612:2;6599:55;6684:36;6678:2;6665:55;6750:36;6744:2;6731:55;6816:36;6810:2;6797:55;6882:36;6876:2;6863:55;6948:36;6942:2;6929:55;7014:36;7008:2;6995:55;7080:36;7074:2;7061:55;7146:36;7140:2;7127:55;7212:36;7206:2;7193:55;7278:36;7272:2;7259:55;7344:36;7338:2;7325:55;7410:36;7404:2;7391:55;7476:36;7470:2;7457:55;7542:36;7536:2;7523:55;7608:36;7602:2;7589:55;7674:36;7668:2;7655:55;7740:36;7734:2;7721:55;7806:36;7800:2;7787:55;7872:36;7866:2;7853:55;7938:36;7932:2;7919:55;8004:36;7998:2;7985:55;8070:36;8064:2;8051:55;8136:36;8130:2;8117:55;8202:36;8196:2;8183:55;8268:36;8262:2;8249:55;8334:36;8328:2;8315:55;8400:36;8394:2;8381:55;8466:36;8460:2;8447:55;8532:36;8525:3;8513:55;8598:36;8591:3;8579:55;8664:36;8657:3;8645:55;8730:36;8723:3;8711:55;8796:36;8789:3;8777:55;8862:36;8855:3;8843:55;8928:36;8921:3;8909:55;8994:36;8987:3;8975:55;9060:36;9053:3;9041:55;9126:36;9119:3;9107:55;9192:36;9185:3;9173:55;9258:36;9251:3;9239:55;9324:36;9317:3;9305:55;9390:36;9383:3;9371:55;9456:36;9449:3;9437:55;9522:36;9515:3;9503:55;9588:36;9581:3;9569:55;9654:36;9647:3;9635:55;9720:36;9713:3;9701:55;9786:36;9779:3;9767:55;9852:36;9845:3;9833:55;9918:36;9911:3;9899:55;9984:36;9977:3;9965:55;10050:36;10043:3;10031:55;10116:36;10109:3;10097:55;10182:36;10175:3;10163:55;10248:36;10241:3;10229:55;10314:36;4025:11;10307:3;10295:16;;:55;1867:8491::o;10456:8364::-;10523:34;10503:12;:54;;;10588:34;10568:17;:54;10653:34;10633:17;:54;10718:34;10698:17;:54;10783:34;10763:17;:54;10848:34;10828:17;:54;10913:34;10893:17;:54;10978:34;10958:17;:54;11043:34;11023:17;:54;11108:34;11088:17;:54;11173:34;11153:17;:54;11238:34;11218:17;:54;11303:34;11283:17;:54;11368:34;11348:17;:54;11433:34;11413:17;:54;11498:34;11478:17;:54;11563:34;11543:17;:54;11628:34;11608:17;:54;11693:34;11673:17;:54;11758:34;11738:17;:54;11823:34;11803:17;:54;11888:34;11868:17;:54;11953:34;11933:17;:54;12018:34;11998:17;:54;12083:34;12063:17;:54;12148:34;12128:17;:54;12213:34;12193:17;:54;12278:34;12258:17;:54;12343:34;12323:17;:54;12408:34;12388:17;:54;12473:34;12453:17;:54;12538:34;12518:17;:54;12603:34;12583:17;:54;12668:34;12648:17;:54;12733:34;12713:17;:54;12798:34;12778:17;:54;12863:34;12843:17;:54;12928:34;12908:17;:54;12993:34;12973:17;:54;13058:34;13038:17;:54;13123:34;13103:17;:54;13188:34;13168:17;:54;13253:34;13233:17;:54;13318:34;13298:17;:54;13383:34;13363:17;:54;13448:34;13428:17;:54;13513:34;13493:17;:54;13578:34;13558:17;:54;13643:34;13623:17;:54;13708:34;13688:17;:54;13773:34;13753:17;:54;13838:34;13818:17;:54;13903:34;13883:17;:54;13968:34;13948:17;:54;14033:34;14013:17;:54;14098:34;14078:17;:54;14163:34;14143:17;:54;14228:34;14208:17;:54;14293:34;14273:17;:54;14358:34;14338:17;:54;14423:34;14403:17;:54;14488:34;14468:17;:54;14553:34;14533:17;:54;14618:34;14598:17;:54;14683:34;14663:17;:54;14748:34;14728:17;:54;14813:34;14793:17;:54;14878:34;14858:17;:54;14943:34;14923:17;:54;15008:34;14988:17;:54;15073:34;15053:17;:54;15138:34;15118:17;:54;15203:34;15183:17;:54;15268:34;15248:17;:54;15333:34;15313:17;:54;15398:34;15378:17;:54;15463:34;15443:17;:54;15528:34;15508:17;:54;15593:34;15573:17;:54;15658:34;15638:17;:54;15723:34;15703:17;:54;15788:34;15768:17;:54;15853:34;15833:17;:54;15918:34;15898:17;:54;15983:34;15963:17;:54;16048:34;16028:17;:54;16113:34;16093:17;:54;16178:34;16158:17;:54;16243:34;16223:17;:54;16308:34;16288:17;:54;16373:34;16353:17;:54;16438:34;16418:17;:54;16503:34;16483:17;:54;16568:34;16548:17;:54;16633:34;16613:17;:54;16698:34;16678:17;:54;16763:34;16743:17;:54;16828:34;16808:17;:54;16893:34;16873:17;:54;16958:34;16938:17;:54;17023:34;17003:17;:54;17088:34;17068:17;:54;17153:34;17133:17;:54;17218:34;17198:17;:54;17283:34;17263:17;:54;17348:34;17328:17;:54;17413:34;17393:17;:54;17478:34;17458:17;:54;17543:34;17523:17;:54;17608:34;17588:17;:54;17673:34;17653:17;:54;17738:34;17718:17;:54;17803:34;17783:17;:54;17868:34;17848:17;:54;17933:34;17913:17;:54;17998:34;17978:17;:54;18063:34;18043:17;:54;18128:34;18108:17;:54;18193:34;18173:17;:54;18258:34;18238:17;:54;18323:34;18303:17;:54;18388:34;18368:17;:54;18453:34;18433:17;:54;18518:34;18498:17;:54;18583:34;18563:17;:54;18648:34;18628:17;:54;18713:34;18693:17;:54;18778:34;;18771:3;18758:17;;44252:2798;44306:7;;;;;44425:34;44420:39;;44416:143;;-1:-1:-1;;;44462:41:7;;;;44523:34;-1:-1:-1;;;44509:1:7;:11;:48;;;;;;44505:52;;44416:143;44593:34;44588:1;:39;44584:143;;-1:-1:-1;;;44630:41:7;;;;44691:34;-1:-1:-1;;;44677:1:7;:11;:48;;;;;;44673:52;;44584:143;44761:34;44756:1;:39;44752:143;;-1:-1:-1;;;44798:41:7;;;;44859:34;-1:-1:-1;;;44845:1:7;:11;:48;;;;;;44841:52;;44752:143;44929:34;44924:1;:39;44920:143;;-1:-1:-1;;;44966:41:7;;;;45027:34;-1:-1:-1;;;45013:1:7;:11;:48;;;;;;45009:52;;44920:143;45097:34;45092:1;:39;45088:143;;-1:-1:-1;;;45134:41:7;;;;45195:34;-1:-1:-1;;;45181:1:7;:11;:48;;;;;;45177:52;;45088:143;45265:34;45260:1;:39;45256:143;;-1:-1:-1;;;45302:41:7;;;;45363:34;-1:-1:-1;;;45349:1:7;:11;:48;;;;;;45345:52;;45256:143;45433:34;45428:1;:39;45424:143;;-1:-1:-1;;;45470:41:7;;;;45531:34;-1:-1:-1;;;45517:1:7;:11;:48;;;;;;45513:52;;45424:143;45601:34;45596:1;:39;45592:143;;-1:-1:-1;;;45638:41:7;;;;45699:34;-1:-1:-1;;;45685:1:7;:11;:48;;;;;;45681:52;;45592:143;-1:-1:-1;;45770:11:7;;;-1:-1:-1;45770:11:7;;-1:-1:-1;;;;45796:5:7;;;:15;;-1:-1:-1;;;;45834:39:7;;;45829:45;;:83;45822:90;;;;-1:-1:-1;;;45922:1:7;45918;:5;:15;;;;;;45914:19;;-1:-1:-1;;;46023:1:7;45985:35;:39;45980:1;:45;:83;;;;;;45973:90;;;;-1:-1:-1;;;46073:1:7;46069;:5;:15;;;;;;46065:19;;-1:-1:-1;;;46174:1:7;46136:35;:39;46131:1;:45;:83;;;;;;46124:90;;;;-1:-1:-1;;;46224:1:7;46220;:5;:15;;;;;;46216:19;;-1:-1:-1;;;46325:1:7;46287:35;:39;46282:1;:45;:83;;;;;;46275:90;;;;-1:-1:-1;;;46375:1:7;46371;:5;:15;;;;;;46367:19;;-1:-1:-1;;;46476:1:7;46438:35;:39;46433:1;:45;:83;;;;;;46426:90;;;;-1:-1:-1;;;46526:1:7;46522;:5;:15;;;;;;46518:19;;-1:-1:-1;;;46627:1:7;46589:35;:39;46584:1;:45;:83;;;;;;46577:90;;;;-1:-1:-1;;;46677:1:7;46673;:5;:15;;;;;;46669:19;;-1:-1:-1;;;46778:1:7;46740:35;:39;46735:1;:45;:83;;;;;;46728:90;;;;-1:-1:-1;;;46828:1:7;46824;:5;:15;;;;;;46820:19;;-1:-1:-1;;;46929:1:7;46891:35;:39;46886:1;:45;:83;;;;;;46879:90;;;;;-1:-1:-1;;;;44252:2798:7;;;;:::o;36707:823::-;36761:7;;-1:-1:-1;;;36905:12:7;;36901:156;;36934:11;36948:22;-1:-1:-1;;;36958:1:7;:11;;36948:9;:22::i;:::-;36985:11;;;;;;-1:-1:-1;;;37030:15:7;;-1:-1:-1;;36901:156:7;-1:-1:-1;;;37165:1:7;:11;37161:305;;;417:3;37193:262;37223:5;;;;37193:262;;-1:-1:-1;;;37259:5:7;;;37258:17;37254:21;;-1:-1:-1;;;37315:1:7;:12;37311:129;;37358:1;37352:7;;;;37406:14;-1:-1:-1;;37414:5:7;;37406:14;;37399:21;;;;;37311:129;-1:-1:-1;;37230:3:7;37193:262;;;;37161:305;898:33;815;37485:19;;:37;;36707:823;-1:-1:-1;;;36707:823:7:o;47747:3216::-;47801:7;48185:18;-1:-1:-1;;;47899:38:7;;;47983:5;;;:15;;;48070:5;;;:15;;;48157:5;;;:15;;;48181:22;;;48011:18;48007:22;;;48098:18;48094:22;;;;48087:29;48174;;47899:38;;48244:5;;;:15;48240:19;;48268:1;48272:18;48268:22;48261:29;;;;-1:-1:-1;;;48335:1:7;48331;:5;:15;;;;;;48327:19;;48355:1;48359:18;48355:22;48348:29;;;;-1:-1:-1;;;48422:1:7;48418;:5;:15;;;;;;48414:19;;48442:1;48446:18;48442:22;48435:29;;;;-1:-1:-1;;;48509:1:7;48505;:5;:15;;;;;;48501:19;;48529:1;48533:18;48529:22;48522:29;;;;-1:-1:-1;;;48596:1:7;48592;:5;:15;;;;;;48588:19;;48616:1;48620:18;48616:22;48609:29;;;;-1:-1:-1;;;48683:1:7;48679;:5;:15;;;;;;48675:19;;48703:1;48707:18;48703:22;48696:29;;;;-1:-1:-1;;;48770:1:7;48766;:5;:15;;;;;;48762:19;;48790:1;48794:18;48790:22;48783:29;;;;-1:-1:-1;;;48857:1:7;48853;:5;:15;;;;;;48849:19;;48877:1;48881:18;48877:22;48870:29;;;;-1:-1:-1;;;48944:1:7;48940;:5;:15;;;;;;48936:19;;48964:1;48968:18;48964:22;48957:29;;;;-1:-1:-1;;;49031:1:7;49027;:5;:15;;;;;;49023:19;;49051:1;49055:18;49051:22;49044:29;;;;-1:-1:-1;;;49118:1:7;49114;:5;:15;;;;;;49110:19;;49138:1;49142:18;49138:22;49131:29;;;;-1:-1:-1;;;49205:1:7;49201;:5;:15;;;;;;49197:19;;49225:1;49229:18;49225:22;49218:29;;;;-1:-1:-1;;;49292:1:7;49288;:5;:15;;;;;;49284:19;;49312:1;49316:18;49312:22;49305:29;;;;-1:-1:-1;;;49379:1:7;49375;:5;:15;;;;;;49371:19;;49399:1;49403:18;49399:22;49392:29;;;;-1:-1:-1;;;49466:1:7;49462;:5;:15;;;;;;49458:19;;49486:1;49490:18;49486:22;49479:29;;;;-1:-1:-1;;;49553:1:7;49549;:5;:15;;;;;49644:18;49549:15;;;49566:29;;;49638:24;:28;;-1:-1:-1;;;49638:38:7;;49549:15;-1:-1:-1;;;;49744:39:7;;49743:46;49739:137;;49841:35;49803;49797:41;;:79;49791:85;;49739:137;-1:-1:-1;;;49916:39:7;;49915:46;49911:137;;50013:35;49975;49969:41;;:79;49963:85;;49911:137;-1:-1:-1;;;50088:39:7;;50087:46;50083:137;;50185:35;50147;50141:41;;:79;50135:85;;50083:137;-1:-1:-1;;;50260:39:7;;50259:46;50255:137;;50357:35;50319;50313:41;;:79;50307:85;;50255:137;-1:-1:-1;;;50432:39:7;;50431:46;50427:137;;50529:35;50491;50485:41;;:79;50479:85;;50427:137;-1:-1:-1;;;50604:39:7;;50603:46;50599:137;;50701:35;50663;50657:41;;:79;50651:85;;50599:137;-1:-1:-1;;;50776:39:7;;50775:46;50771:137;;50873:35;50835;50829:41;;:79;50823:85;;50771:137;-1:-1:-1;50952:3:7;;47747:3216;-1:-1:-1;;;47747:3216:7:o;38573:501::-;38643:5;369:2;417:3;38733:185;38749:2;38740:11;;:2;38745:1;38740:6;:11;;;38733:185;;;38768:9;38792:1;38780:13;38781:7;;;38780:13;;38768:25;;38832:2;38812:11;38824:3;38812:16;;;;;;;;;;;:22;38808:98;;38858:3;38853:8;;38808:98;;;38903:3;38898:8;;38808:98;38733:185;;;;38953:2;38934:11;38946:2;38934:15;;;;;;;;;;;:21;38930:49;;38977:2;-1:-1:-1;38970:9:7;;-1:-1:-1;38970:9:7;38930:49;39013:2;38994:11;39006:2;38994:15;;;;;;;;;;;:21;38990:49;;-1:-1:-1;39037:2:7;-1:-1:-1;39030:9:7;;39646:3864;39719:7;39739:10;39752:2;39739:15;;39765:11;39811:10;39798:23;;39804:2;39799;:7;39798:23;;39793:28;;39830:2;39835:33;39830:38;39823:45;;;;39923:10;39910:23;;39916:2;39911;:7;39910:23;;39905:28;;39942:2;39947:33;39942:38;39935:45;;;;40035:10;40022:23;;40028:2;40023;:7;40022:23;;40017:28;;40054:2;40059:33;40054:38;40047:45;;;;40147:10;40134:23;;40140:2;40135;:7;40134:23;;40129:28;;40166:2;40171:33;40166:38;40159:45;;;;40259:10;40246:23;;40252:2;40247;:7;40246:23;;40241:28;;40278:2;40283:33;40278:38;40271:45;;;;40371:10;40358:23;;40364:2;40359;:7;40358:23;;40353:28;;40390:2;40395:33;40390:38;40383:45;;;;40483:10;40470:23;;40476:2;40471;:7;40470:23;;40465:28;;40502:2;40507:33;40502:38;40495:45;;;;40595:10;40582:23;;40588:2;40583;:7;40582:23;;40577:28;;40614:2;40619:33;40614:38;40607:45;;;;40707:10;40694:23;;40700:2;40695;:7;40694:23;;40689:28;;40726:2;40731:33;40726:38;40719:45;;;;40819:10;40806:23;;40812:2;40807;:7;40806:23;;40801:28;;40838:2;40843:33;40838:38;40831:45;;;;40931:10;40918:23;;40924:2;40919;:7;40918:23;;40913:28;;40950:2;40955:33;40950:38;40943:45;;;;41043:10;41030:23;;41036:2;41031;:7;41030:23;;41025:28;;41062:2;41067:33;41062:38;41055:45;;;;41155:10;41142:23;;41148:2;41143;:7;41142:23;;41137:28;;41174:2;41179:33;41174:38;41167:45;;;;41267:10;41254:23;;41260:2;41255;:7;41254:23;;41249:28;;41286:2;41291:33;41286:38;41279:45;;;;41379:10;41366:23;;41372:2;41367;:7;41366:23;;41361:28;;41398:2;41403:33;41398:38;41391:45;;;;41491:10;41478:23;;41484:2;41479;:7;41478:23;;41473:28;;41510:2;41515:33;41510:38;41503:45;;;;41603:10;41590:23;;41596:2;41591;:7;41590:23;;41585:28;;41622:2;41627:33;41622:38;41615:45;;;;41715:10;41702:23;;41708:2;41703;:7;41702:23;;41697:28;;41734:2;41739:33;41734:38;41727:45;;;;41827:10;41814:23;;41820:2;41815;:7;41814:23;;41809:28;;41846:2;41851:33;41846:38;41839:45;;;;41939:10;41926:23;;41932:2;41927;:7;41926:23;;41921:28;;41958:2;41963:33;41958:38;41951:45;;;;42051:10;42038:23;;42044:2;42039;:7;42038:23;;42033:28;;42070:2;42075:33;42070:38;42063:45;;;;42163:10;42150:23;;42156:2;42151;:7;42150:23;;42145:28;;42182:2;42187:33;42182:38;42175:45;;;;42275:10;42262:23;;42268:2;42263;:7;42262:23;;42257:28;;42294:2;42299:33;42294:38;42287:45;;;;42387:10;42374:23;;42380:2;42375;:7;42374:23;;42369:28;;42406:2;42411:33;42406:38;42399:45;;;;42499:10;42486:23;;42492:2;42487;:7;42486:23;;42481:28;;42518:2;42523:33;42518:38;42511:45;;;;42611:10;42598:23;;42604:2;42599;:7;42598:23;;42593:28;;42630:2;42635:33;42630:38;42623:45;;;;42723:10;42710:23;;42716:2;42711;:7;42710:23;;42705:28;;42742:2;42747:33;42742:38;42735:45;;;;42835:10;42822:23;;42828:2;42823;:7;42822:23;;42817:28;;42854:2;42859:33;42854:38;42847:45;;;;42947:10;42934:23;;42940:2;42935;:7;42934:23;;42929:28;;42966:2;42971:33;42966:38;42959:45;;;;43059:10;43046:23;;43052:2;43047;:7;43046:23;;43041:28;;43078:2;43083:33;43078:38;43071:45;;;;43171:10;43158:23;;43164:2;43159;:7;43158:23;;43153:28;;43190:2;43195:33;43190:38;43183:45;;;;43283:10;43270:23;;43276:2;43271;:7;43270:23;;43265:28;;43302:2;43307:33;43302:38;43295:45;;;;43441:10;43434:17;;271:1;43434:17;;43428:2;43392:33;43386:3;:39;;;;;;:44;:66;;39646:3864;-1:-1:-1;;;;;39646:3864:7:o;63076:444::-;63144:7;63153;-1:-1:-1;;;63177:2:7;:13;;:30;;;;;-1:-1:-1;;;63194:2:7;:13;;63177:30;63173:64;;;-1:-1:-1;63230:2:7;;-1:-1:-1;63234:2:7;63222:15;;63173:64;-1:-1:-1;;;63252:2:7;:12;63248:66;;;63302:2;-1:-1:-1;;;63287:2:7;:12;:17;;;;;;-1:-1:-1;;;63279:35:7;;;;;;63248:66;-1:-1:-1;;;63329:2:7;:12;63325:66;;;-1:-1:-1;;;63388:2:7;-1:-1:-1;;;63373:2:7;:12;:17;;;;;;63356:35;;;;;;63325:66;63402:9;63419:2;63414;:7;:17;;63429:2;63414:17;;;63424:2;63414:17;63402:29;-1:-1:-1;63442:9:7;63454:22;-1:-1:-1;;;63402:29:7;63464:11;;63454:22;63442:34;;63495:7;;;;63504;;;;;-1:-1:-1;;;;63076:444:7:o;51471:190::-;51527:7;1300:36;51551:2;:25;51547:66;;51598:15;51610:2;51598:11;:15::i;:::-;51591:22;;;;51547:66;51651:2;-1:-1:-1;;;51651:2:7;51631:22;;;;;;51471:190;-1:-1:-1;;51471:190:7:o;51052:328::-;51107:7;1300:36;51131:2;:25;51127:66;;51178:15;51190:2;51178:11;:15::i;51127:66::-;1480:36;51208:2;:25;51204:66;;51255:15;51267:2;51255:11;:15::i;51204:66::-;1570:36;51285:2;:25;51281:66;;51332:15;51344:2;51332:11;:15::i;64005:380::-;64077:6;64085;1708:62;64108:2;:19;64104:137;;;64184:1;64162:18;64156:25;;:29;;:2;:29;64200:7;;;;;;;64228:1;64222:7;;;;;;;;;64104:137;;64251:9;64263:37;316:7;64272:15;;64289:10;64272:2;64296;64289:6;:10::i;:::-;64263:8;:37::i;:::-;64251:49;316:7;64323:14;;;;-1:-1:-1;64005:380:7;-1:-1:-1;;;;64005:380:7:o;37658:542::-;37712:5;;37765:3;37760:8;;37756:414;;;37822:85;37834:1;37829:2;:6;37822:85;;;37863:1;37856:8;;;;37883;37822:85;;;37756:414;;;38000:3;37985:174;38005:5;;;;37985:174;;271:1;38051:8;;;;38044:16;;38040:104;;38085:8;;;;;;;;38116;;;;38040:104;38018:1;38012:7;;;37985:174;;;;38189:3;37658:542;-1:-1:-1;;37658:542:7:o;57726:4616::-;57782:7;57815:2;57782:7;-1:-1:-1;;;57862:7:7;;;57861:19;;-1:-1:-1;57894:44:7;57889:49;;57882:56;-1:-1:-1;;;57997:7:7;;;57996:19;;-1:-1:-1;58029:44:7;58024:49;;58017:56;-1:-1:-1;;;58132:7:7;;;58131:19;;-1:-1:-1;58164:44:7;58159:49;;58152:56;-1:-1:-1;;;58267:7:7;;;58266:19;;-1:-1:-1;58299:44:7;58294:49;;58287:56;-1:-1:-1;;;58402:7:7;;;58401:19;;-1:-1:-1;58434:44:7;58429:49;;58422:56;-1:-1:-1;;;58537:7:7;;;58536:19;;-1:-1:-1;58569:44:7;58564:49;;58557:56;-1:-1:-1;;;58672:7:7;;;58671:19;;-1:-1:-1;58704:44:7;58699:49;;58692:56;-1:-1:-1;;;58807:7:7;;;58806:19;;-1:-1:-1;58839:44:7;58834:49;;58827:56;-1:-1:-1;;;58942:7:7;;;58941:19;;-1:-1:-1;58974:44:7;58969:49;;58962:56;-1:-1:-1;;;59077:7:7;;;59076:19;;-1:-1:-1;59109:44:7;59104:49;;59097:56;-1:-1:-1;;;59212:7:7;;;59211:19;;-1:-1:-1;59244:44:7;59239:49;;59232:56;-1:-1:-1;;;59347:7:7;;;59346:19;;-1:-1:-1;59379:44:7;59374:49;;59367:56;-1:-1:-1;;;59482:7:7;;;59481:19;;-1:-1:-1;59514:44:7;59509:49;;59502:56;-1:-1:-1;;;59617:7:7;;;59616:19;;-1:-1:-1;;;;59644:49:7;;59637:56;-1:-1:-1;;;59752:7:7;;;59751:19;;-1:-1:-1;59784:44:7;59779:49;;59772:56;-1:-1:-1;;;59887:7:7;;;59886:19;;-1:-1:-1;59919:44:7;59914:49;;59907:56;-1:-1:-1;;;60022:7:7;;;60021:19;;-1:-1:-1;60054:44:7;60049:49;;60042:56;-1:-1:-1;;;60157:7:7;;;60156:19;;-1:-1:-1;60189:44:7;60184:49;;60177:56;-1:-1:-1;;;60292:7:7;;;60291:19;;-1:-1:-1;60324:44:7;60319:49;;60312:56;-1:-1:-1;;;60427:7:7;;;60426:19;;-1:-1:-1;60459:44:7;60454:49;;60447:56;-1:-1:-1;;;60562:7:7;;;60561:19;;-1:-1:-1;60594:44:7;60589:49;;60582:56;-1:-1:-1;;;60697:7:7;;;60696:19;;-1:-1:-1;;;;60724:49:7;;60717:56;-1:-1:-1;;;60832:7:7;;;60831:19;;-1:-1:-1;60864:44:7;60859:49;;60852:56;-1:-1:-1;;;60967:7:7;;;60966:19;;-1:-1:-1;60999:44:7;60994:49;;60987:56;-1:-1:-1;;;61102:7:7;;;61101:19;;-1:-1:-1;61134:44:7;61129:49;;61122:56;-1:-1:-1;;;61237:7:7;;;61236:19;;-1:-1:-1;;;;61264:49:7;;61257:56;-1:-1:-1;;;61372:7:7;;;61371:19;;-1:-1:-1;61404:44:7;61399:49;;61392:56;-1:-1:-1;;;61507:7:7;;;61506:19;;-1:-1:-1;61539:44:7;61534:49;;61527:56;-1:-1:-1;;;61642:7:7;;;61641:19;;-1:-1:-1;61674:44:7;61669:49;;61662:56;-1:-1:-1;;;61777:7:7;;;61776:19;;-1:-1:-1;;;;61804:49:7;;61797:56;-1:-1:-1;;;61912:7:7;;;61911:19;;-1:-1:-1;61944:44:7;61939:49;;61932:56;-1:-1:-1;;;62047:7:7;;;62046:19;;-1:-1:-1;62079:44:7;62074:49;;62067:56;-1:-1:-1;;;62228:2:7;62191:34;62067:56;62185:40;:45;:55;;57726:4616;-1:-1:-1;;;;57726:4616:7:o;51856:4641::-;51912:7;51945:2;-1:-1:-1;;;51973:12:7;;;51989:34;51972:51;;52109:7;;;52108:19;;-1:-1:-1;52141:44:7;52136:49;;52129:56;-1:-1:-1;;;52244:7:7;;;52243:19;;-1:-1:-1;52276:44:7;52271:49;;52264:56;;-1:-1:-1;;;52379:7:7;;;52378:19;;-1:-1:-1;52411:44:7;52406:49;;52399:56;-1:-1:-1;;;52514:7:7;;;52513:19;;-1:-1:-1;52546:44:7;52541:49;;52534:56;;-1:-1:-1;;;52649:7:7;;;52648:19;;-1:-1:-1;52681:44:7;52676:49;;52669:56;-1:-1:-1;;;52784:7:7;;;52783:19;;-1:-1:-1;52816:44:7;52811:49;;52804:56;;-1:-1:-1;;;52919:7:7;;;52918:19;;-1:-1:-1;52951:44:7;52946:49;;52939:56;-1:-1:-1;;;53054:7:7;;;53053:19;;-1:-1:-1;53086:44:7;53081:49;;53074:56;;-1:-1:-1;;;53189:7:7;;;53188:19;;-1:-1:-1;53221:44:7;53216:49;;53209:56;-1:-1:-1;;;53324:7:7;;;53323:19;;-1:-1:-1;53356:44:7;53351:49;;53344:56;;-1:-1:-1;;;53459:7:7;;;53458:19;;-1:-1:-1;53491:44:7;53486:49;;53479:56;-1:-1:-1;;;53594:7:7;;;53593:19;;-1:-1:-1;53626:44:7;53621:49;;53614:56;;-1:-1:-1;;;53729:7:7;;;53728:19;;-1:-1:-1;53761:44:7;53756:49;;53749:56;-1:-1:-1;;;53864:7:7;;;53863:19;;-1:-1:-1;;;;53891:49:7;;53884:56;;-1:-1:-1;;;53999:7:7;;;53998:19;;-1:-1:-1;54031:44:7;54026:49;;54019:56;-1:-1:-1;;;54134:7:7;;;54133:19;;-1:-1:-1;54166:44:7;54161:49;;54154:56;;-1:-1:-1;;;54269:7:7;;;54268:19;;-1:-1:-1;54301:44:7;54296:49;;54289:56;-1:-1:-1;;;54404:7:7;;;54403:19;;-1:-1:-1;54436:44:7;54431:49;;54424:56;;-1:-1:-1;;;54539:7:7;;;54538:19;;-1:-1:-1;54571:44:7;54566:49;;54559:56;-1:-1:-1;;;54674:7:7;;;54673:19;;-1:-1:-1;54706:44:7;54701:49;;54694:56;;-1:-1:-1;;;54809:7:7;;;54808:19;;-1:-1:-1;54841:44:7;54836:49;;54829:56;-1:-1:-1;;;54944:7:7;;;54943:19;;-1:-1:-1;;;;54971:49:7;;54964:56;;-1:-1:-1;;;55079:7:7;;;55078:19;;-1:-1:-1;55111:44:7;55106:49;;55099:56;-1:-1:-1;;;55214:7:7;;;55213:19;;-1:-1:-1;55246:44:7;55241:49;;55234:56;;-1:-1:-1;;;55349:7:7;;;55348:19;;-1:-1:-1;55381:44:7;55376:49;;55369:56;-1:-1:-1;;;55484:7:7;;;55483:19;;-1:-1:-1;;;;55511:49:7;;55504:56;;-1:-1:-1;;;55619:7:7;;;55618:19;;-1:-1:-1;55651:44:7;55646:49;;55639:56;-1:-1:-1;;;55754:7:7;;;55753:19;;-1:-1:-1;55786:44:7;55781:49;;55774:56;;-1:-1:-1;;;55889:7:7;;;55888:19;;-1:-1:-1;55921:44:7;55916:49;;55909:56;-1:-1:-1;;;56024:7:7;;;56023:19;;-1:-1:-1;;;;56051:49:7;;56044:56;;-1:-1:-1;;;56159:7:7;;;56158:19;;-1:-1:-1;56191:44:7;56186:49;;56179:56;-1:-1:-1;;;56294:7:7;;;56293:19;;-1:-1:-1;56326:44:7;56321:49;;56314:56;;56438:34;56314:56;56432:40;;;51856:4641;-1:-1:-1;;;;51856:4641:7:o;56660:415::-;56716:7;-1:-1:-1;;56748:28:7;;1390:36;56799:23;;;;56845;;;;56918:1;56914:5;;56891:29;56716:7;56943:12;56799:23;56943:15;;;;;;;;;56931:27;;56969:9;56981:12;56994:1;56998;56994:5;56981:19;;;;;;;;;1390:36;57038:5;;;57033:11;57024:5;;;;57019:11;:25;;;;57018:49;;;-1:-1:-1;;;;56660:415:7:o;57238:291::-;57294:7;57314:10;1072:35;57327:2;:20;:54;;57367:14;57378:2;57367:10;:14::i;:::-;57327:54;;;57350:14;57361:2;57350:10;:14::i;:::-;57314:67;;57392:10;1072:35;57405:2;:20;:54;;57445:14;57456:2;57445:10;:14::i;:::-;57405:54;;;57428:14;57439:2;57428:10;:14::i;:::-;57392:67;;57519:2;-1:-1:-1;;;57503:2:7;-1:-1:-1;;;57488:2:7;:12;:17;;;;;;57483:2;57478;:7;:27;57477:39;:44;;;;64510:133;64575:7;64633:1;64628:2;:6;64623:2;:11;64617:2;64612;:7;;;;;;:23;;;;;;64607:2;64602;:7;;;;;;:33;;64510:133;-1:-1:-1;;;64510:133:7:o",
+ "source": "// SPDX-License-Identifier: SEE LICENSE IN LICENSE\r\npragma solidity 0.6.12;\r\nimport \"./interfaces/IBancorFormula.sol\";\r\nimport \"../utility/SafeMath.sol\";\r\n\r\ncontract BancorFormula is IBancorFormula {\r\n using SafeMath for uint256;\r\n\r\n uint256 private constant ONE = 1;\r\n uint32 private constant MAX_WEIGHT = 1000000;\r\n uint8 private constant MIN_PRECISION = 32;\r\n uint8 private constant MAX_PRECISION = 127;\r\n\r\n // Auto-generated via 'PrintIntScalingFactors.py'\r\n uint256 private constant FIXED_1 = 0x080000000000000000000000000000000;\r\n uint256 private constant FIXED_2 = 0x100000000000000000000000000000000;\r\n uint256 private constant MAX_NUM = 0x200000000000000000000000000000000;\r\n\r\n // Auto-generated via 'PrintLn2ScalingFactors.py'\r\n uint256 private constant LN2_NUMERATOR = 0x3f80fe03f80fe03f80fe03f80fe03f8;\r\n uint256 private constant LN2_DENOMINATOR = 0x5b9de1d10bf4103d647b0955897ba80;\r\n\r\n // Auto-generated via 'PrintFunctionOptimalLog.py' and 'PrintFunctionOptimalExp.py'\r\n uint256 private constant OPT_LOG_MAX_VAL = 0x15bf0a8b1457695355fb8ac404e7a79e3;\r\n uint256 private constant OPT_EXP_MAX_VAL = 0x800000000000000000000000000000000;\r\n\r\n // Auto-generated via 'PrintLambertFactors.py'\r\n uint256 private constant LAMBERT_CONV_RADIUS = 0x002f16ac6c59de6f8d5d6f63c1482a7c86;\r\n uint256 private constant LAMBERT_POS2_SAMPLE = 0x0003060c183060c183060c183060c18306;\r\n uint256 private constant LAMBERT_POS2_MAXVAL = 0x01af16ac6c59de6f8d5d6f63c1482a7c80;\r\n uint256 private constant LAMBERT_POS3_MAXVAL = 0x6b22d43e72c326539cceeef8bb48f255ff;\r\n\r\n // Auto-generated via 'PrintWeightFactors.py'\r\n uint256 private constant MAX_UNF_WEIGHT = 0x10c6f7a0b5ed8d36b4c7f34938583621fafc8b0079a2834d26fa3fcc9ea9;\r\n\r\n // Auto-generated via 'PrintMaxExpArray.py'\r\n uint256[128] private maxExpArray;\r\n function initMaxExpArray() private {\r\n // maxExpArray[ 0] = 0x6bffffffffffffffffffffffffffffffff;\r\n // maxExpArray[ 1] = 0x67ffffffffffffffffffffffffffffffff;\r\n // maxExpArray[ 2] = 0x637fffffffffffffffffffffffffffffff;\r\n // maxExpArray[ 3] = 0x5f6fffffffffffffffffffffffffffffff;\r\n // maxExpArray[ 4] = 0x5b77ffffffffffffffffffffffffffffff;\r\n // maxExpArray[ 5] = 0x57b3ffffffffffffffffffffffffffffff;\r\n // maxExpArray[ 6] = 0x5419ffffffffffffffffffffffffffffff;\r\n // maxExpArray[ 7] = 0x50a2ffffffffffffffffffffffffffffff;\r\n // maxExpArray[ 8] = 0x4d517fffffffffffffffffffffffffffff;\r\n // maxExpArray[ 9] = 0x4a233fffffffffffffffffffffffffffff;\r\n // maxExpArray[ 10] = 0x47165fffffffffffffffffffffffffffff;\r\n // maxExpArray[ 11] = 0x4429afffffffffffffffffffffffffffff;\r\n // maxExpArray[ 12] = 0x415bc7ffffffffffffffffffffffffffff;\r\n // maxExpArray[ 13] = 0x3eab73ffffffffffffffffffffffffffff;\r\n // maxExpArray[ 14] = 0x3c1771ffffffffffffffffffffffffffff;\r\n // maxExpArray[ 15] = 0x399e96ffffffffffffffffffffffffffff;\r\n // maxExpArray[ 16] = 0x373fc47fffffffffffffffffffffffffff;\r\n // maxExpArray[ 17] = 0x34f9e8ffffffffffffffffffffffffffff;\r\n // maxExpArray[ 18] = 0x32cbfd5fffffffffffffffffffffffffff;\r\n // maxExpArray[ 19] = 0x30b5057fffffffffffffffffffffffffff;\r\n // maxExpArray[ 20] = 0x2eb40f9fffffffffffffffffffffffffff;\r\n // maxExpArray[ 21] = 0x2cc8340fffffffffffffffffffffffffff;\r\n // maxExpArray[ 22] = 0x2af09481ffffffffffffffffffffffffff;\r\n // maxExpArray[ 23] = 0x292c5bddffffffffffffffffffffffffff;\r\n // maxExpArray[ 24] = 0x277abdcdffffffffffffffffffffffffff;\r\n // maxExpArray[ 25] = 0x25daf6657fffffffffffffffffffffffff;\r\n // maxExpArray[ 26] = 0x244c49c65fffffffffffffffffffffffff;\r\n // maxExpArray[ 27] = 0x22ce03cd5fffffffffffffffffffffffff;\r\n // maxExpArray[ 28] = 0x215f77c047ffffffffffffffffffffffff;\r\n // maxExpArray[ 29] = 0x1fffffffffffffffffffffffffffffffff;\r\n // maxExpArray[ 30] = 0x1eaefdbdabffffffffffffffffffffffff;\r\n // maxExpArray[ 31] = 0x1d6bd8b2ebffffffffffffffffffffffff;\r\n maxExpArray[ 32] = 0x1c35fedd14ffffffffffffffffffffffff;\r\n maxExpArray[ 33] = 0x1b0ce43b323fffffffffffffffffffffff;\r\n maxExpArray[ 34] = 0x19f0028ec1ffffffffffffffffffffffff;\r\n maxExpArray[ 35] = 0x18ded91f0e7fffffffffffffffffffffff;\r\n maxExpArray[ 36] = 0x17d8ec7f0417ffffffffffffffffffffff;\r\n maxExpArray[ 37] = 0x16ddc6556cdbffffffffffffffffffffff;\r\n maxExpArray[ 38] = 0x15ecf52776a1ffffffffffffffffffffff;\r\n maxExpArray[ 39] = 0x15060c256cb2ffffffffffffffffffffff;\r\n maxExpArray[ 40] = 0x1428a2f98d72ffffffffffffffffffffff;\r\n maxExpArray[ 41] = 0x13545598e5c23fffffffffffffffffffff;\r\n maxExpArray[ 42] = 0x1288c4161ce1dfffffffffffffffffffff;\r\n maxExpArray[ 43] = 0x11c592761c666fffffffffffffffffffff;\r\n maxExpArray[ 44] = 0x110a688680a757ffffffffffffffffffff;\r\n maxExpArray[ 45] = 0x1056f1b5bedf77ffffffffffffffffffff;\r\n maxExpArray[ 46] = 0x0faadceceeff8bffffffffffffffffffff;\r\n maxExpArray[ 47] = 0x0f05dc6b27edadffffffffffffffffffff;\r\n maxExpArray[ 48] = 0x0e67a5a25da4107fffffffffffffffffff;\r\n maxExpArray[ 49] = 0x0dcff115b14eedffffffffffffffffffff;\r\n maxExpArray[ 50] = 0x0d3e7a392431239fffffffffffffffffff;\r\n maxExpArray[ 51] = 0x0cb2ff529eb71e4fffffffffffffffffff;\r\n maxExpArray[ 52] = 0x0c2d415c3db974afffffffffffffffffff;\r\n maxExpArray[ 53] = 0x0bad03e7d883f69bffffffffffffffffff;\r\n maxExpArray[ 54] = 0x0b320d03b2c343d5ffffffffffffffffff;\r\n maxExpArray[ 55] = 0x0abc25204e02828dffffffffffffffffff;\r\n maxExpArray[ 56] = 0x0a4b16f74ee4bb207fffffffffffffffff;\r\n maxExpArray[ 57] = 0x09deaf736ac1f569ffffffffffffffffff;\r\n maxExpArray[ 58] = 0x0976bd9952c7aa957fffffffffffffffff;\r\n maxExpArray[ 59] = 0x09131271922eaa606fffffffffffffffff;\r\n maxExpArray[ 60] = 0x08b380f3558668c46fffffffffffffffff;\r\n maxExpArray[ 61] = 0x0857ddf0117efa215bffffffffffffffff;\r\n maxExpArray[ 62] = 0x07ffffffffffffffffffffffffffffffff;\r\n maxExpArray[ 63] = 0x07abbf6f6abb9d087fffffffffffffffff;\r\n maxExpArray[ 64] = 0x075af62cbac95f7dfa7fffffffffffffff;\r\n maxExpArray[ 65] = 0x070d7fb7452e187ac13fffffffffffffff;\r\n maxExpArray[ 66] = 0x06c3390ecc8af379295fffffffffffffff;\r\n maxExpArray[ 67] = 0x067c00a3b07ffc01fd6fffffffffffffff;\r\n maxExpArray[ 68] = 0x0637b647c39cbb9d3d27ffffffffffffff;\r\n maxExpArray[ 69] = 0x05f63b1fc104dbd39587ffffffffffffff;\r\n maxExpArray[ 70] = 0x05b771955b36e12f7235ffffffffffffff;\r\n maxExpArray[ 71] = 0x057b3d49dda84556d6f6ffffffffffffff;\r\n maxExpArray[ 72] = 0x054183095b2c8ececf30ffffffffffffff;\r\n maxExpArray[ 73] = 0x050a28be635ca2b888f77fffffffffffff;\r\n maxExpArray[ 74] = 0x04d5156639708c9db33c3fffffffffffff;\r\n maxExpArray[ 75] = 0x04a23105873875bd52dfdfffffffffffff;\r\n maxExpArray[ 76] = 0x0471649d87199aa990756fffffffffffff;\r\n maxExpArray[ 77] = 0x04429a21a029d4c1457cfbffffffffffff;\r\n maxExpArray[ 78] = 0x0415bc6d6fb7dd71af2cb3ffffffffffff;\r\n maxExpArray[ 79] = 0x03eab73b3bbfe282243ce1ffffffffffff;\r\n maxExpArray[ 80] = 0x03c1771ac9fb6b4c18e229ffffffffffff;\r\n maxExpArray[ 81] = 0x0399e96897690418f785257fffffffffff;\r\n maxExpArray[ 82] = 0x0373fc456c53bb779bf0ea9fffffffffff;\r\n maxExpArray[ 83] = 0x034f9e8e490c48e67e6ab8bfffffffffff;\r\n maxExpArray[ 84] = 0x032cbfd4a7adc790560b3337ffffffffff;\r\n maxExpArray[ 85] = 0x030b50570f6e5d2acca94613ffffffffff;\r\n maxExpArray[ 86] = 0x02eb40f9f620fda6b56c2861ffffffffff;\r\n maxExpArray[ 87] = 0x02cc8340ecb0d0f520a6af58ffffffffff;\r\n maxExpArray[ 88] = 0x02af09481380a0a35cf1ba02ffffffffff;\r\n maxExpArray[ 89] = 0x0292c5bdd3b92ec810287b1b3fffffffff;\r\n maxExpArray[ 90] = 0x0277abdcdab07d5a77ac6d6b9fffffffff;\r\n maxExpArray[ 91] = 0x025daf6654b1eaa55fd64df5efffffffff;\r\n maxExpArray[ 92] = 0x0244c49c648baa98192dce88b7ffffffff;\r\n maxExpArray[ 93] = 0x022ce03cd5619a311b2471268bffffffff;\r\n maxExpArray[ 94] = 0x0215f77c045fbe885654a44a0fffffffff;\r\n maxExpArray[ 95] = 0x01ffffffffffffffffffffffffffffffff;\r\n maxExpArray[ 96] = 0x01eaefdbdaaee7421fc4d3ede5ffffffff;\r\n maxExpArray[ 97] = 0x01d6bd8b2eb257df7e8ca57b09bfffffff;\r\n maxExpArray[ 98] = 0x01c35fedd14b861eb0443f7f133fffffff;\r\n maxExpArray[ 99] = 0x01b0ce43b322bcde4a56e8ada5afffffff;\r\n maxExpArray[100] = 0x019f0028ec1fff007f5a195a39dfffffff;\r\n maxExpArray[101] = 0x018ded91f0e72ee74f49b15ba527ffffff;\r\n maxExpArray[102] = 0x017d8ec7f04136f4e5615fd41a63ffffff;\r\n maxExpArray[103] = 0x016ddc6556cdb84bdc8d12d22e6fffffff;\r\n maxExpArray[104] = 0x015ecf52776a1155b5bd8395814f7fffff;\r\n maxExpArray[105] = 0x015060c256cb23b3b3cc3754cf40ffffff;\r\n maxExpArray[106] = 0x01428a2f98d728ae223ddab715be3fffff;\r\n maxExpArray[107] = 0x013545598e5c23276ccf0ede68034fffff;\r\n maxExpArray[108] = 0x01288c4161ce1d6f54b7f61081194fffff;\r\n maxExpArray[109] = 0x011c592761c666aa641d5a01a40f17ffff;\r\n maxExpArray[110] = 0x0110a688680a7530515f3e6e6cfdcdffff;\r\n maxExpArray[111] = 0x01056f1b5bedf75c6bcb2ce8aed428ffff;\r\n maxExpArray[112] = 0x00faadceceeff8a0890f3875f008277fff;\r\n maxExpArray[113] = 0x00f05dc6b27edad306388a600f6ba0bfff;\r\n maxExpArray[114] = 0x00e67a5a25da41063de1495d5b18cdbfff;\r\n maxExpArray[115] = 0x00dcff115b14eedde6fc3aa5353f2e4fff;\r\n maxExpArray[116] = 0x00d3e7a3924312399f9aae2e0f868f8fff;\r\n maxExpArray[117] = 0x00cb2ff529eb71e41582cccd5a1ee26fff;\r\n maxExpArray[118] = 0x00c2d415c3db974ab32a51840c0b67edff;\r\n maxExpArray[119] = 0x00bad03e7d883f69ad5b0a186184e06bff;\r\n maxExpArray[120] = 0x00b320d03b2c343d4829abd6075f0cc5ff;\r\n maxExpArray[121] = 0x00abc25204e02828d73c6e80bcdb1a95bf;\r\n maxExpArray[122] = 0x00a4b16f74ee4bb2040a1ec6c15fbbf2df;\r\n maxExpArray[123] = 0x009deaf736ac1f569deb1b5ae3f36c130f;\r\n maxExpArray[124] = 0x00976bd9952c7aa957f5937d790ef65037;\r\n maxExpArray[125] = 0x009131271922eaa6064b73a22d0bd4f2bf;\r\n maxExpArray[126] = 0x008b380f3558668c46c91c49a2f8e967b9;\r\n maxExpArray[127] = 0x00857ddf0117efa215952912839f6473e6;\r\n }\r\n\r\n // Auto-generated via 'PrintLambertArray.py'\r\n uint256[128] private lambertArray;\r\n function initLambertArray() private {\r\n lambertArray[ 0] = 0x60e393c68d20b1bd09deaabc0373b9c5;\r\n lambertArray[ 1] = 0x5f8f46e4854120989ed94719fb4c2011;\r\n lambertArray[ 2] = 0x5e479ebb9129fb1b7e72a648f992b606;\r\n lambertArray[ 3] = 0x5d0bd23fe42dfedde2e9586be12b85fe;\r\n lambertArray[ 4] = 0x5bdb29ddee979308ddfca81aeeb8095a;\r\n lambertArray[ 5] = 0x5ab4fd8a260d2c7e2c0d2afcf0009dad;\r\n lambertArray[ 6] = 0x5998b31359a55d48724c65cf09001221;\r\n lambertArray[ 7] = 0x5885bcad2b322dfc43e8860f9c018cf5;\r\n lambertArray[ 8] = 0x577b97aa1fe222bb452fdf111b1f0be2;\r\n lambertArray[ 9] = 0x5679cb5e3575632e5baa27e2b949f704;\r\n lambertArray[ 10] = 0x557fe8241b3a31c83c732f1cdff4a1c5;\r\n lambertArray[ 11] = 0x548d868026504875d6e59bbe95fc2a6b;\r\n lambertArray[ 12] = 0x53a2465ce347cf34d05a867c17dd3088;\r\n lambertArray[ 13] = 0x52bdce5dcd4faed59c7f5511cf8f8acc;\r\n lambertArray[ 14] = 0x51dfcb453c07f8da817606e7885f7c3e;\r\n lambertArray[ 15] = 0x5107ef6b0a5a2be8f8ff15590daa3cce;\r\n lambertArray[ 16] = 0x5035f241d6eae0cd7bacba119993de7b;\r\n lambertArray[ 17] = 0x4f698fe90d5b53d532171e1210164c66;\r\n lambertArray[ 18] = 0x4ea288ca297a0e6a09a0eee240e16c85;\r\n lambertArray[ 19] = 0x4de0a13fdcf5d4213fc398ba6e3becde;\r\n lambertArray[ 20] = 0x4d23a145eef91fec06b06140804c4808;\r\n lambertArray[ 21] = 0x4c6b5430d4c1ee5526473db4ae0f11de;\r\n lambertArray[ 22] = 0x4bb7886c240562eba11f4963a53b4240;\r\n lambertArray[ 23] = 0x4b080f3f1cb491d2d521e0ea4583521e;\r\n lambertArray[ 24] = 0x4a5cbc96a05589cb4d86be1db3168364;\r\n lambertArray[ 25] = 0x49b566d40243517658d78c33162d6ece;\r\n lambertArray[ 26] = 0x4911e6a02e5507a30f947383fd9a3276;\r\n lambertArray[ 27] = 0x487216c2b31be4adc41db8a8d5cc0c88;\r\n lambertArray[ 28] = 0x47d5d3fc4a7a1b188cd3d788b5c5e9fc;\r\n lambertArray[ 29] = 0x473cfce4871a2c40bc4f9e1c32b955d0;\r\n lambertArray[ 30] = 0x46a771ca578ab878485810e285e31c67;\r\n lambertArray[ 31] = 0x4615149718aed4c258c373dc676aa72d;\r\n lambertArray[ 32] = 0x4585c8b3f8fe489c6e1833ca47871384;\r\n lambertArray[ 33] = 0x44f972f174e41e5efb7e9d63c29ce735;\r\n lambertArray[ 34] = 0x446ff970ba86d8b00beb05ecebf3c4dc;\r\n lambertArray[ 35] = 0x43e9438ec88971812d6f198b5ccaad96;\r\n lambertArray[ 36] = 0x436539d11ff7bea657aeddb394e809ef;\r\n lambertArray[ 37] = 0x42e3c5d3e5a913401d86f66db5d81c2c;\r\n lambertArray[ 38] = 0x4264d2395303070ea726cbe98df62174;\r\n lambertArray[ 39] = 0x41e84a9a593bb7194c3a6349ecae4eea;\r\n lambertArray[ 40] = 0x416e1b785d13eba07a08f3f18876a5ab;\r\n lambertArray[ 41] = 0x40f6322ff389d423ba9dd7e7e7b7e809;\r\n lambertArray[ 42] = 0x40807cec8a466880ecf4184545d240a4;\r\n lambertArray[ 43] = 0x400cea9ce88a8d3ae668e8ea0d9bf07f;\r\n lambertArray[ 44] = 0x3f9b6ae8772d4c55091e0ed7dfea0ac1;\r\n lambertArray[ 45] = 0x3f2bee253fd84594f54bcaafac383a13;\r\n lambertArray[ 46] = 0x3ebe654e95208bb9210c575c081c5958;\r\n lambertArray[ 47] = 0x3e52c1fc5665635b78ce1f05ad53c086;\r\n lambertArray[ 48] = 0x3de8f65ac388101ddf718a6f5c1eff65;\r\n lambertArray[ 49] = 0x3d80f522d59bd0b328ca012df4cd2d49;\r\n lambertArray[ 50] = 0x3d1ab193129ea72b23648a161163a85a;\r\n lambertArray[ 51] = 0x3cb61f68d32576c135b95cfb53f76d75;\r\n lambertArray[ 52] = 0x3c5332d9f1aae851a3619e77e4cc8473;\r\n lambertArray[ 53] = 0x3bf1e08edbe2aa109e1525f65759ef73;\r\n lambertArray[ 54] = 0x3b921d9cff13fa2c197746a3dfc4918f;\r\n lambertArray[ 55] = 0x3b33df818910bfc1a5aefb8f63ae2ac4;\r\n lambertArray[ 56] = 0x3ad71c1c77e34fa32a9f184967eccbf6;\r\n lambertArray[ 57] = 0x3a7bc9abf2c5bb53e2f7384a8a16521a;\r\n lambertArray[ 58] = 0x3a21dec7e76369783a68a0c6385a1c57;\r\n lambertArray[ 59] = 0x39c9525de6c9cdf7c1c157ca4a7a6ee3;\r\n lambertArray[ 60] = 0x39721bad3dc85d1240ff0190e0adaac3;\r\n lambertArray[ 61] = 0x391c324344d3248f0469eb28dd3d77e0;\r\n lambertArray[ 62] = 0x38c78df7e3c796279fb4ff84394ab3da;\r\n lambertArray[ 63] = 0x387426ea4638ae9aae08049d3554c20a;\r\n lambertArray[ 64] = 0x3821f57dbd2763256c1a99bbd2051378;\r\n lambertArray[ 65] = 0x37d0f256cb46a8c92ff62fbbef289698;\r\n lambertArray[ 66] = 0x37811658591ffc7abdd1feaf3cef9b73;\r\n lambertArray[ 67] = 0x37325aa10e9e82f7df0f380f7997154b;\r\n lambertArray[ 68] = 0x36e4b888cfb408d873b9a80d439311c6;\r\n lambertArray[ 69] = 0x3698299e59f4bb9de645fc9b08c64cca;\r\n lambertArray[ 70] = 0x364ca7a5012cb603023b57dd3ebfd50d;\r\n lambertArray[ 71] = 0x36022c928915b778ab1b06aaee7e61d4;\r\n lambertArray[ 72] = 0x35b8b28d1a73dc27500ffe35559cc028;\r\n lambertArray[ 73] = 0x357033e951fe250ec5eb4e60955132d7;\r\n lambertArray[ 74] = 0x3528ab2867934e3a21b5412e4c4f8881;\r\n lambertArray[ 75] = 0x34e212f66c55057f9676c80094a61d59;\r\n lambertArray[ 76] = 0x349c66289e5b3c4b540c24f42fa4b9bb;\r\n lambertArray[ 77] = 0x34579fbbd0c733a9c8d6af6b0f7d00f7;\r\n lambertArray[ 78] = 0x3413bad2e712288b924b5882b5b369bf;\r\n lambertArray[ 79] = 0x33d0b2b56286510ef730e213f71f12e9;\r\n lambertArray[ 80] = 0x338e82ce00e2496262c64457535ba1a1;\r\n lambertArray[ 81] = 0x334d26a96b373bb7c2f8ea1827f27a92;\r\n lambertArray[ 82] = 0x330c99f4f4211469e00b3e18c31475ea;\r\n lambertArray[ 83] = 0x32ccd87d6486094999c7d5e6f33237d8;\r\n lambertArray[ 84] = 0x328dde2dd617b6665a2e8556f250c1af;\r\n lambertArray[ 85] = 0x324fa70e9adc270f8262755af5a99af9;\r\n lambertArray[ 86] = 0x32122f443110611ca51040f41fa6e1e3;\r\n lambertArray[ 87] = 0x31d5730e42c0831482f0f1485c4263d8;\r\n lambertArray[ 88] = 0x31996ec6b07b4a83421b5ebc4ab4e1f1;\r\n lambertArray[ 89] = 0x315e1ee0a68ff46bb43ec2b85032e876;\r\n lambertArray[ 90] = 0x31237fe7bc4deacf6775b9efa1a145f8;\r\n lambertArray[ 91] = 0x30e98e7f1cc5a356e44627a6972ea2ff;\r\n lambertArray[ 92] = 0x30b04760b8917ec74205a3002650ec05;\r\n lambertArray[ 93] = 0x3077a75c803468e9132ce0cf3224241d;\r\n lambertArray[ 94] = 0x303fab57a6a275c36f19cda9bace667a;\r\n lambertArray[ 95] = 0x3008504beb8dcbd2cf3bc1f6d5a064f0;\r\n lambertArray[ 96] = 0x2fd19346ed17dac61219ce0c2c5ac4b0;\r\n lambertArray[ 97] = 0x2f9b7169808c324b5852fd3d54ba9714;\r\n lambertArray[ 98] = 0x2f65e7e711cf4b064eea9c08cbdad574;\r\n lambertArray[ 99] = 0x2f30f405093042ddff8a251b6bf6d103;\r\n lambertArray[100] = 0x2efc931a3750f2e8bfe323edfe037574;\r\n lambertArray[101] = 0x2ec8c28e46dbe56d98685278339400cb;\r\n lambertArray[102] = 0x2e957fd933c3926d8a599b602379b851;\r\n lambertArray[103] = 0x2e62c882c7c9ed4473412702f08ba0e5;\r\n lambertArray[104] = 0x2e309a221c12ba361e3ed695167feee2;\r\n lambertArray[105] = 0x2dfef25d1f865ae18dd07cfea4bcea10;\r\n lambertArray[106] = 0x2dcdcee821cdc80decc02c44344aeb31;\r\n lambertArray[107] = 0x2d9d2d8562b34944d0b201bb87260c83;\r\n lambertArray[108] = 0x2d6d0c04a5b62a2c42636308669b729a;\r\n lambertArray[109] = 0x2d3d6842c9a235517fc5a0332691528f;\r\n lambertArray[110] = 0x2d0e402963fe1ea2834abc408c437c10;\r\n lambertArray[111] = 0x2cdf91ae602647908aff975e4d6a2a8c;\r\n lambertArray[112] = 0x2cb15ad3a1eb65f6d74a75da09a1b6c5;\r\n lambertArray[113] = 0x2c8399a6ab8e9774d6fcff373d210727;\r\n lambertArray[114] = 0x2c564c4046f64edba6883ca06bbc4535;\r\n lambertArray[115] = 0x2c2970c431f952641e05cb493e23eed3;\r\n lambertArray[116] = 0x2bfd0560cd9eb14563bc7c0732856c18;\r\n lambertArray[117] = 0x2bd1084ed0332f7ff4150f9d0ef41a2c;\r\n lambertArray[118] = 0x2ba577d0fa1628b76d040b12a82492fb;\r\n lambertArray[119] = 0x2b7a5233cd21581e855e89dc2f1e8a92;\r\n lambertArray[120] = 0x2b4f95cd46904d05d72bdcde337d9cc7;\r\n lambertArray[121] = 0x2b2540fc9b4d9abba3faca6691914675;\r\n lambertArray[122] = 0x2afb5229f68d0830d8be8adb0a0db70f;\r\n lambertArray[123] = 0x2ad1c7c63a9b294c5bc73a3ba3ab7a2b;\r\n lambertArray[124] = 0x2aa8a04ac3cbe1ee1c9c86361465dbb8;\r\n lambertArray[125] = 0x2a7fda392d725a44a2c8aeb9ab35430d;\r\n lambertArray[126] = 0x2a57741b18cde618717792b4faa216db;\r\n lambertArray[127] = 0x2a2f6c81f5d84dd950a35626d6d5503a;\r\n }\r\n\r\n /**\r\n * @dev should be executed after construction (too large for the constructor)\r\n */\r\n function init() public {\r\n initMaxExpArray();\r\n initLambertArray();\r\n }\r\n\r\n /**\r\n * @dev given a token supply, reserve balance, weight and a deposit amount (in the reserve token),\r\n * calculates the target amount for a given conversion (in the main token)\r\n *\r\n * Formula:\r\n * return = _supply * ((1 + _amount / _reserveBalance) ^ (_reserveWeight / 1000000) - 1)\r\n *\r\n * @param _supply smart token supply\r\n * @param _reserveBalance reserve balance\r\n * @param _reserveWeight reserve weight, represented in ppm (1-1000000)\r\n * @param _amount amount of reserve tokens to get the target amount for\r\n *\r\n * @return smart token amount\r\n */\r\n function purchaseTargetAmount(uint256 _supply,\r\n uint256 _reserveBalance,\r\n uint32 _reserveWeight,\r\n uint256 _amount)\r\n public view override returns (uint256)\r\n {\r\n // validate input\r\n require(_supply > 0, \"ERR_INVALID_SUPPLY\");\r\n require(_reserveBalance > 0, \"ERR_INVALID_RESERVE_BALANCE\");\r\n require(_reserveWeight > 0 && _reserveWeight <= MAX_WEIGHT, \"ERR_INVALID_RESERVE_WEIGHT\");\r\n\r\n // special case for 0 deposit amount\r\n if (_amount == 0)\r\n return 0;\r\n\r\n // special case if the weight = 100%\r\n if (_reserveWeight == MAX_WEIGHT)\r\n return _supply.mul(_amount) / _reserveBalance;\r\n\r\n uint256 result;\r\n uint8 precision;\r\n uint256 baseN = _amount.add(_reserveBalance);\r\n (result, precision) = power(baseN, _reserveBalance, _reserveWeight, MAX_WEIGHT);\r\n uint256 temp = _supply.mul(result) >> precision;\r\n return temp - _supply;\r\n }\r\n\r\n /**\r\n * @dev given a token supply, reserve balance, weight and a sell amount (in the main token),\r\n * calculates the target amount for a given conversion (in the reserve token)\r\n *\r\n * Formula:\r\n * return = _reserveBalance * (1 - (1 - _amount / _supply) ^ (1000000 / _reserveWeight))\r\n *\r\n * @param _supply smart token supply\r\n * @param _reserveBalance reserve balance\r\n * @param _reserveWeight reserve weight, represented in ppm (1-1000000)\r\n * @param _amount amount of smart tokens to get the target amount for\r\n *\r\n * @return reserve token amount\r\n */\r\n function saleTargetAmount(uint256 _supply,\r\n uint256 _reserveBalance,\r\n uint32 _reserveWeight,\r\n uint256 _amount)\r\n public view override returns (uint256)\r\n {\r\n // validate input\r\n require(_supply > 0, \"ERR_INVALID_SUPPLY\");\r\n require(_reserveBalance > 0, \"ERR_INVALID_RESERVE_BALANCE\");\r\n require(_reserveWeight > 0 && _reserveWeight <= MAX_WEIGHT, \"ERR_INVALID_RESERVE_WEIGHT\");\r\n require(_amount <= _supply, \"ERR_INVALID_AMOUNT\");\r\n\r\n // special case for 0 sell amount\r\n if (_amount == 0)\r\n return 0;\r\n\r\n // special case for selling the entire supply\r\n if (_amount == _supply)\r\n return _reserveBalance;\r\n\r\n // special case if the weight = 100%\r\n if (_reserveWeight == MAX_WEIGHT)\r\n return _reserveBalance.mul(_amount) / _supply;\r\n\r\n uint256 result;\r\n uint8 precision;\r\n uint256 baseD = _supply - _amount;\r\n (result, precision) = power(_supply, baseD, MAX_WEIGHT, _reserveWeight);\r\n uint256 temp1 = _reserveBalance.mul(result);\r\n uint256 temp2 = _reserveBalance << precision;\r\n return (temp1 - temp2) / result;\r\n }\r\n\r\n /**\r\n * @dev given two reserve balances/weights and a sell amount (in the first reserve token),\r\n * calculates the target amount for a conversion from the source reserve token to the target reserve token\r\n *\r\n * Formula:\r\n * return = _targetReserveBalance * (1 - (_sourceReserveBalance / (_sourceReserveBalance + _amount)) ^ (_sourceReserveWeight / _targetReserveWeight))\r\n *\r\n * @param _sourceReserveBalance source reserve balance\r\n * @param _sourceReserveWeight source reserve weight, represented in ppm (1-1000000)\r\n * @param _targetReserveBalance target reserve balance\r\n * @param _targetReserveWeight target reserve weight, represented in ppm (1-1000000)\r\n * @param _amount source reserve amount\r\n *\r\n * @return target reserve amount\r\n */\r\n function crossReserveTargetAmount(uint256 _sourceReserveBalance,\r\n uint32 _sourceReserveWeight,\r\n uint256 _targetReserveBalance,\r\n uint32 _targetReserveWeight,\r\n uint256 _amount)\r\n public view override returns (uint256)\r\n {\r\n // validate input\r\n require(_sourceReserveBalance > 0 && _targetReserveBalance > 0, \"ERR_INVALID_RESERVE_BALANCE\");\r\n require(_sourceReserveWeight > 0 && _sourceReserveWeight <= MAX_WEIGHT &&\r\n _targetReserveWeight > 0 && _targetReserveWeight <= MAX_WEIGHT, \"ERR_INVALID_RESERVE_WEIGHT\");\r\n\r\n // special case for equal weights\r\n if (_sourceReserveWeight == _targetReserveWeight)\r\n return _targetReserveBalance.mul(_amount) / _sourceReserveBalance.add(_amount);\r\n\r\n uint256 result;\r\n uint8 precision;\r\n uint256 baseN = _sourceReserveBalance.add(_amount);\r\n (result, precision) = power(baseN, _sourceReserveBalance, _sourceReserveWeight, _targetReserveWeight);\r\n uint256 temp1 = _targetReserveBalance.mul(result);\r\n uint256 temp2 = _targetReserveBalance << precision;\r\n return (temp1 - temp2) / result;\r\n }\r\n\r\n /**\r\n * @dev given a smart token supply, reserve balance, reserve ratio and an amount of requested smart tokens,\r\n * calculates the amount of reserve tokens required for purchasing the given amount of smart tokens\r\n *\r\n * Formula:\r\n * return = _reserveBalance * (((_supply + _amount) / _supply) ^ (MAX_WEIGHT / _reserveRatio) - 1)\r\n *\r\n * @param _supply smart token supply\r\n * @param _reserveBalance reserve balance\r\n * @param _reserveRatio reserve ratio, represented in ppm (2-2000000)\r\n * @param _amount requested amount of smart tokens\r\n *\r\n * @return reserve token amount\r\n */\r\n function fundCost(uint256 _supply,\r\n uint256 _reserveBalance,\r\n uint32 _reserveRatio,\r\n uint256 _amount)\r\n public view override returns (uint256)\r\n {\r\n // validate input\r\n require(_supply > 0, \"ERR_INVALID_SUPPLY\");\r\n require(_reserveBalance > 0, \"ERR_INVALID_RESERVE_BALANCE\");\r\n require(_reserveRatio > 1 && _reserveRatio <= MAX_WEIGHT * 2, \"ERR_INVALID_RESERVE_RATIO\");\r\n\r\n // special case for 0 amount\r\n if (_amount == 0)\r\n return 0;\r\n\r\n // special case if the reserve ratio = 100%\r\n if (_reserveRatio == MAX_WEIGHT)\r\n return (_amount.mul(_reserveBalance) - 1) / _supply + 1;\r\n\r\n uint256 result;\r\n uint8 precision;\r\n uint256 baseN = _supply.add(_amount);\r\n (result, precision) = power(baseN, _supply, MAX_WEIGHT, _reserveRatio);\r\n uint256 temp = ((_reserveBalance.mul(result) - 1) >> precision) + 1;\r\n return temp - _reserveBalance;\r\n }\r\n\r\n /**\r\n * @dev given a smart token supply, reserve balance, reserve ratio and an amount of reserve tokens to fund with,\r\n * calculates the amount of smart tokens received for purchasing with the given amount of reserve tokens\r\n *\r\n * Formula:\r\n * return = _supply * ((_amount / _reserveBalance + 1) ^ (_reserveRatio / MAX_WEIGHT) - 1)\r\n *\r\n * @param _supply smart token supply\r\n * @param _reserveBalance reserve balance\r\n * @param _reserveRatio reserve ratio, represented in ppm (2-2000000)\r\n * @param _amount amount of reserve tokens to fund with\r\n *\r\n * @return smart token amount\r\n */\r\n function fundSupplyAmount(uint256 _supply,\r\n uint256 _reserveBalance,\r\n uint32 _reserveRatio,\r\n uint256 _amount)\r\n public view override returns (uint256)\r\n {\r\n // validate input\r\n require(_supply > 0, \"ERR_INVALID_SUPPLY\");\r\n require(_reserveBalance > 0, \"ERR_INVALID_RESERVE_BALANCE\");\r\n require(_reserveRatio > 1 && _reserveRatio <= MAX_WEIGHT * 2, \"ERR_INVALID_RESERVE_RATIO\");\r\n\r\n // special case for 0 amount\r\n if (_amount == 0)\r\n return 0;\r\n\r\n // special case if the reserve ratio = 100%\r\n if (_reserveRatio == MAX_WEIGHT)\r\n return _amount.mul(_supply) / _reserveBalance;\r\n\r\n uint256 result;\r\n uint8 precision;\r\n uint256 baseN = _reserveBalance.add(_amount);\r\n (result, precision) = power(baseN, _reserveBalance, _reserveRatio, MAX_WEIGHT);\r\n uint256 temp = _supply.mul(result) >> precision;\r\n return temp - _supply;\r\n }\r\n\r\n /**\r\n * @dev given a smart token supply, reserve balance, reserve ratio and an amount of smart tokens to liquidate,\r\n * calculates the amount of reserve tokens received for selling the given amount of smart tokens\r\n *\r\n * Formula:\r\n * return = _reserveBalance * (1 - ((_supply - _amount) / _supply) ^ (MAX_WEIGHT / _reserveRatio))\r\n *\r\n * @param _supply smart token supply\r\n * @param _reserveBalance reserve balance\r\n * @param _reserveRatio reserve ratio, represented in ppm (2-2000000)\r\n * @param _amount amount of smart tokens to liquidate\r\n *\r\n * @return reserve token amount\r\n */\r\n function liquidateReserveAmount(uint256 _supply,\r\n uint256 _reserveBalance,\r\n uint32 _reserveRatio,\r\n uint256 _amount)\r\n public view override returns (uint256)\r\n {\r\n // validate input\r\n require(_supply > 0, \"ERR_INVALID_SUPPLY\");\r\n require(_reserveBalance > 0, \"ERR_INVALID_RESERVE_BALANCE\");\r\n require(_reserveRatio > 1 && _reserveRatio <= MAX_WEIGHT * 2, \"ERR_INVALID_RESERVE_RATIO\");\r\n require(_amount <= _supply, \"ERR_INVALID_AMOUNT\");\r\n\r\n // special case for 0 amount\r\n if (_amount == 0)\r\n return 0;\r\n\r\n // special case for liquidating the entire supply\r\n if (_amount == _supply)\r\n return _reserveBalance;\r\n\r\n // special case if the reserve ratio = 100%\r\n if (_reserveRatio == MAX_WEIGHT)\r\n return _amount.mul(_reserveBalance) / _supply;\r\n\r\n uint256 result;\r\n uint8 precision;\r\n uint256 baseD = _supply - _amount;\r\n (result, precision) = power(_supply, baseD, MAX_WEIGHT, _reserveRatio);\r\n uint256 temp1 = _reserveBalance.mul(result);\r\n uint256 temp2 = _reserveBalance << precision;\r\n return (temp1 - temp2) / result;\r\n }\r\n\r\n /**\r\n * @dev The arbitrage incentive is to convert to the point where the on-chain price is equal to the off-chain price.\r\n * We want this operation to also impact the primary reserve balance becoming equal to the primary reserve staked balance.\r\n * In other words, we want the arbitrager to convert the difference between the reserve balance and the reserve staked balance.\r\n *\r\n * Formula input:\r\n * - let t denote the primary reserve token staked balance\r\n * - let s denote the primary reserve token balance\r\n * - let r denote the secondary reserve token balance\r\n * - let q denote the numerator of the rate between the tokens\r\n * - let p denote the denominator of the rate between the tokens\r\n * Where p primary tokens are equal to q secondary tokens\r\n *\r\n * Formula output:\r\n * - compute x = W(t / r * q / p * log(s / t)) / log(s / t)\r\n * - return x / (1 + x) as the weight of the primary reserve token\r\n * - return 1 / (1 + x) as the weight of the secondary reserve token\r\n * Where W is the Lambert W Function\r\n *\r\n * If the rate-provider provides the rates for a common unit, for example:\r\n * - P = 2 ==> 2 primary reserve tokens = 1 ether\r\n * - Q = 3 ==> 3 secondary reserve tokens = 1 ether\r\n * Then you can simply use p = P and q = Q\r\n *\r\n * If the rate-provider provides the rates for a single unit, for example:\r\n * - P = 2 ==> 1 primary reserve token = 2 ethers\r\n * - Q = 3 ==> 1 secondary reserve token = 3 ethers\r\n * Then you can simply use p = Q and q = P\r\n *\r\n * @param _primaryReserveStakedBalance the primary reserve token staked balance\r\n * @param _primaryReserveBalance the primary reserve token balance\r\n * @param _secondaryReserveBalance the secondary reserve token balance\r\n * @param _reserveRateNumerator the numerator of the rate between the tokens\r\n * @param _reserveRateDenominator the denominator of the rate between the tokens\r\n *\r\n * Note that `numerator / denominator` should represent the amount of secondary tokens equal to one primary token\r\n *\r\n * @return the weight of the primary reserve token and the weight of the secondary reserve token, both in ppm (0-1000000)\r\n */\r\n function balancedWeights(uint256 _primaryReserveStakedBalance,\r\n uint256 _primaryReserveBalance,\r\n uint256 _secondaryReserveBalance,\r\n uint256 _reserveRateNumerator,\r\n uint256 _reserveRateDenominator)\r\n public view override returns (uint32, uint32)\r\n {\r\n if (_primaryReserveStakedBalance == _primaryReserveBalance)\r\n require(_primaryReserveStakedBalance > 0 || _secondaryReserveBalance > 0, \"ERR_INVALID_RESERVE_BALANCE\");\r\n else\r\n require(_primaryReserveStakedBalance > 0 && _primaryReserveBalance > 0 && _secondaryReserveBalance > 0, \"ERR_INVALID_RESERVE_BALANCE\");\r\n require(_reserveRateNumerator > 0 && _reserveRateDenominator > 0, \"ERR_INVALID_RESERVE_RATE\");\r\n\r\n uint256 tq = _primaryReserveStakedBalance.mul(_reserveRateNumerator);\r\n uint256 rp = _secondaryReserveBalance.mul(_reserveRateDenominator);\r\n\r\n if (_primaryReserveStakedBalance < _primaryReserveBalance)\r\n return balancedWeightsByStake(_primaryReserveBalance, _primaryReserveStakedBalance, tq, rp, true);\r\n\r\n if (_primaryReserveStakedBalance > _primaryReserveBalance)\r\n return balancedWeightsByStake(_primaryReserveStakedBalance, _primaryReserveBalance, tq, rp, false);\r\n\r\n return normalizedWeights(tq, rp);\r\n }\r\n\r\n /**\r\n * @dev General Description:\r\n * Determine a value of precision.\r\n * Calculate an integer approximation of (_baseN / _baseD) ^ (_expN / _expD) * 2 ^ precision.\r\n * Return the result along with the precision used.\r\n *\r\n * Detailed Description:\r\n * Instead of calculating \"base ^ exp\", we calculate \"e ^ (log(base) * exp)\".\r\n * The value of \"log(base)\" is represented with an integer slightly smaller than \"log(base) * 2 ^ precision\".\r\n * The larger \"precision\" is, the more accurately this value represents the real value.\r\n * However, the larger \"precision\" is, the more bits are required in order to store this value.\r\n * And the exponentiation function, which takes \"x\" and calculates \"e ^ x\", is limited to a maximum exponent (maximum value of \"x\").\r\n * This maximum exponent depends on the \"precision\" used, and it is given by \"maxExpArray[precision] >> (MAX_PRECISION - precision)\".\r\n * Hence we need to determine the highest precision which can be used for the given input, before calling the exponentiation function.\r\n * This allows us to compute \"base ^ exp\" with maximum accuracy and without exceeding 256 bits in any of the intermediate computations.\r\n * This functions assumes that \"_expN < 2 ^ 256 / log(MAX_NUM - 1)\", otherwise the multiplication should be replaced with a \"safeMul\".\r\n * Since we rely on unsigned-integer arithmetic and \"base < 1\" ==> \"log(base) < 0\", this function does not support \"_baseN < _baseD\".\r\n */\r\n function power(uint256 _baseN, uint256 _baseD, uint32 _expN, uint32 _expD) internal view returns (uint256, uint8) {\r\n require(_baseN < MAX_NUM);\r\n\r\n uint256 baseLog;\r\n uint256 base = _baseN * FIXED_1 / _baseD;\r\n if (base < OPT_LOG_MAX_VAL) {\r\n baseLog = optimalLog(base);\r\n }\r\n else {\r\n baseLog = generalLog(base);\r\n }\r\n\r\n uint256 baseLogTimesExp = baseLog * _expN / _expD;\r\n if (baseLogTimesExp < OPT_EXP_MAX_VAL) {\r\n return (optimalExp(baseLogTimesExp), MAX_PRECISION);\r\n }\r\n else {\r\n uint8 precision = findPositionInMaxExpArray(baseLogTimesExp);\r\n return (generalExp(baseLogTimesExp >> (MAX_PRECISION - precision), precision), precision);\r\n }\r\n }\r\n\r\n /**\r\n * @dev computes log(x / FIXED_1) * FIXED_1.\r\n * This functions assumes that \"x >= FIXED_1\", because the output would be negative otherwise.\r\n */\r\n function generalLog(uint256 x) internal pure returns (uint256) {\r\n uint256 res = 0;\r\n\r\n // If x >= 2, then we compute the integer part of log2(x), which is larger than 0.\r\n if (x >= FIXED_2) {\r\n uint8 count = floorLog2(x / FIXED_1);\r\n x >>= count; // now x < 2\r\n res = count * FIXED_1;\r\n }\r\n\r\n // If x > 1, then we compute the fraction part of log2(x), which is larger than 0.\r\n if (x > FIXED_1) {\r\n for (uint8 i = MAX_PRECISION; i > 0; --i) {\r\n x = (x * x) / FIXED_1; // now 1 < x < 4\r\n if (x >= FIXED_2) {\r\n x >>= 1; // now 1 < x < 2\r\n res += ONE << (i - 1);\r\n }\r\n }\r\n }\r\n\r\n return res * LN2_NUMERATOR / LN2_DENOMINATOR;\r\n }\r\n\r\n /**\r\n * @dev computes the largest integer smaller than or equal to the binary logarithm of the input.\r\n */\r\n function floorLog2(uint256 _n) internal pure returns (uint8) {\r\n uint8 res = 0;\r\n\r\n if (_n < 256) {\r\n // At most 8 iterations\r\n while (_n > 1) {\r\n _n >>= 1;\r\n res += 1;\r\n }\r\n }\r\n else {\r\n // Exactly 8 iterations\r\n for (uint8 s = 128; s > 0; s >>= 1) {\r\n if (_n >= (ONE << s)) {\r\n _n >>= s;\r\n res |= s;\r\n }\r\n }\r\n }\r\n\r\n return res;\r\n }\r\n\r\n /**\r\n * @dev the global \"maxExpArray\" is sorted in descending order, and therefore the following statements are equivalent:\r\n * - This function finds the position of [the smallest value in \"maxExpArray\" larger than or equal to \"x\"]\r\n * - This function finds the highest position of [a value in \"maxExpArray\" larger than or equal to \"x\"]\r\n */\r\n function findPositionInMaxExpArray(uint256 _x) internal view returns (uint8) {\r\n uint8 lo = MIN_PRECISION;\r\n uint8 hi = MAX_PRECISION;\r\n\r\n while (lo + 1 < hi) {\r\n uint8 mid = (lo + hi) / 2;\r\n if (maxExpArray[mid] >= _x)\r\n lo = mid;\r\n else\r\n hi = mid;\r\n }\r\n\r\n if (maxExpArray[hi] >= _x)\r\n return hi;\r\n if (maxExpArray[lo] >= _x)\r\n return lo;\r\n\r\n require(false);\r\n }\r\n\r\n /**\r\n * @dev this function can be auto-generated by the script 'PrintFunctionGeneralExp.py'.\r\n * it approximates \"e ^ x\" via maclaurin summation: \"(x^0)/0! + (x^1)/1! + ... + (x^n)/n!\".\r\n * it returns \"e ^ (x / 2 ^ precision) * 2 ^ precision\", that is, the result is upshifted for accuracy.\r\n * the global \"maxExpArray\" maps each \"precision\" to \"((maximumExponent + 1) << (MAX_PRECISION - precision)) - 1\".\r\n * the maximum permitted value for \"x\" is therefore given by \"maxExpArray[precision] >> (MAX_PRECISION - precision)\".\r\n */\r\n function generalExp(uint256 _x, uint8 _precision) internal pure returns (uint256) {\r\n uint256 xi = _x;\r\n uint256 res = 0;\r\n\r\n xi = (xi * _x) >> _precision; res += xi * 0x3442c4e6074a82f1797f72ac0000000; // add x^02 * (33! / 02!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x116b96f757c380fb287fd0e40000000; // add x^03 * (33! / 03!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x045ae5bdd5f0e03eca1ff4390000000; // add x^04 * (33! / 04!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x00defabf91302cd95b9ffda50000000; // add x^05 * (33! / 05!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x002529ca9832b22439efff9b8000000; // add x^06 * (33! / 06!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x00054f1cf12bd04e516b6da88000000; // add x^07 * (33! / 07!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x0000a9e39e257a09ca2d6db51000000; // add x^08 * (33! / 08!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x000012e066e7b839fa050c309000000; // add x^09 * (33! / 09!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x000001e33d7d926c329a1ad1a800000; // add x^10 * (33! / 10!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x0000002bee513bdb4a6b19b5f800000; // add x^11 * (33! / 11!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x00000003a9316fa79b88eccf2a00000; // add x^12 * (33! / 12!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x0000000048177ebe1fa812375200000; // add x^13 * (33! / 13!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x0000000005263fe90242dcbacf00000; // add x^14 * (33! / 14!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x000000000057e22099c030d94100000; // add x^15 * (33! / 15!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x0000000000057e22099c030d9410000; // add x^16 * (33! / 16!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x00000000000052b6b54569976310000; // add x^17 * (33! / 17!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x00000000000004985f67696bf748000; // add x^18 * (33! / 18!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x000000000000003dea12ea99e498000; // add x^19 * (33! / 19!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x00000000000000031880f2214b6e000; // add x^20 * (33! / 20!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x000000000000000025bcff56eb36000; // add x^21 * (33! / 21!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x000000000000000001b722e10ab1000; // add x^22 * (33! / 22!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x0000000000000000001317c70077000; // add x^23 * (33! / 23!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x00000000000000000000cba84aafa00; // add x^24 * (33! / 24!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x00000000000000000000082573a0a00; // add x^25 * (33! / 25!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x00000000000000000000005035ad900; // add x^26 * (33! / 26!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x000000000000000000000002f881b00; // add x^27 * (33! / 27!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x0000000000000000000000001b29340; // add x^28 * (33! / 28!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x00000000000000000000000000efc40; // add x^29 * (33! / 29!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x0000000000000000000000000007fe0; // add x^30 * (33! / 30!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x0000000000000000000000000000420; // add x^31 * (33! / 31!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x0000000000000000000000000000021; // add x^32 * (33! / 32!)\r\n xi = (xi * _x) >> _precision; res += xi * 0x0000000000000000000000000000001; // add x^33 * (33! / 33!)\r\n\r\n return res / 0x688589cc0e9505e2f2fee5580000000 + _x + (ONE << _precision); // divide by 33! and then add x^1 / 1! + x^0 / 0!\r\n }\r\n\r\n /**\r\n * @dev computes log(x / FIXED_1) * FIXED_1\r\n * Input range: FIXED_1 <= x <= OPT_LOG_MAX_VAL - 1\r\n * Auto-generated via 'PrintFunctionOptimalLog.py'\r\n * Detailed description:\r\n * - Rewrite the input as a product of natural exponents and a single residual r, such that 1 < r < 2\r\n * - The natural logarithm of each (pre-calculated) exponent is the degree of the exponent\r\n * - The natural logarithm of r is calculated via Taylor series for log(1 + x), where x = r - 1\r\n * - The natural logarithm of the input is calculated by summing up the intermediate results above\r\n * - For example: log(250) = log(e^4 * e^1 * e^0.5 * 1.021692859) = 4 + 1 + 0.5 + log(1 + 0.021692859)\r\n */\r\n function optimalLog(uint256 x) internal pure returns (uint256) {\r\n uint256 res = 0;\r\n\r\n uint256 y;\r\n uint256 z;\r\n uint256 w;\r\n\r\n if (x >= 0xd3094c70f034de4b96ff7d5b6f99fcd8) {res += 0x40000000000000000000000000000000; x = x * FIXED_1 / 0xd3094c70f034de4b96ff7d5b6f99fcd8;} // add 1 / 2^1\r\n if (x >= 0xa45af1e1f40c333b3de1db4dd55f29a7) {res += 0x20000000000000000000000000000000; x = x * FIXED_1 / 0xa45af1e1f40c333b3de1db4dd55f29a7;} // add 1 / 2^2\r\n if (x >= 0x910b022db7ae67ce76b441c27035c6a1) {res += 0x10000000000000000000000000000000; x = x * FIXED_1 / 0x910b022db7ae67ce76b441c27035c6a1;} // add 1 / 2^3\r\n if (x >= 0x88415abbe9a76bead8d00cf112e4d4a8) {res += 0x08000000000000000000000000000000; x = x * FIXED_1 / 0x88415abbe9a76bead8d00cf112e4d4a8;} // add 1 / 2^4\r\n if (x >= 0x84102b00893f64c705e841d5d4064bd3) {res += 0x04000000000000000000000000000000; x = x * FIXED_1 / 0x84102b00893f64c705e841d5d4064bd3;} // add 1 / 2^5\r\n if (x >= 0x8204055aaef1c8bd5c3259f4822735a2) {res += 0x02000000000000000000000000000000; x = x * FIXED_1 / 0x8204055aaef1c8bd5c3259f4822735a2;} // add 1 / 2^6\r\n if (x >= 0x810100ab00222d861931c15e39b44e99) {res += 0x01000000000000000000000000000000; x = x * FIXED_1 / 0x810100ab00222d861931c15e39b44e99;} // add 1 / 2^7\r\n if (x >= 0x808040155aabbbe9451521693554f733) {res += 0x00800000000000000000000000000000; x = x * FIXED_1 / 0x808040155aabbbe9451521693554f733;} // add 1 / 2^8\r\n\r\n z = y = x - FIXED_1;\r\n w = y * y / FIXED_1;\r\n res += z * (0x100000000000000000000000000000000 - y) / 0x100000000000000000000000000000000; z = z * w / FIXED_1; // add y^01 / 01 - y^02 / 02\r\n res += z * (0x0aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa - y) / 0x200000000000000000000000000000000; z = z * w / FIXED_1; // add y^03 / 03 - y^04 / 04\r\n res += z * (0x099999999999999999999999999999999 - y) / 0x300000000000000000000000000000000; z = z * w / FIXED_1; // add y^05 / 05 - y^06 / 06\r\n res += z * (0x092492492492492492492492492492492 - y) / 0x400000000000000000000000000000000; z = z * w / FIXED_1; // add y^07 / 07 - y^08 / 08\r\n res += z * (0x08e38e38e38e38e38e38e38e38e38e38e - y) / 0x500000000000000000000000000000000; z = z * w / FIXED_1; // add y^09 / 09 - y^10 / 10\r\n res += z * (0x08ba2e8ba2e8ba2e8ba2e8ba2e8ba2e8b - y) / 0x600000000000000000000000000000000; z = z * w / FIXED_1; // add y^11 / 11 - y^12 / 12\r\n res += z * (0x089d89d89d89d89d89d89d89d89d89d89 - y) / 0x700000000000000000000000000000000; z = z * w / FIXED_1; // add y^13 / 13 - y^14 / 14\r\n res += z * (0x088888888888888888888888888888888 - y) / 0x800000000000000000000000000000000; // add y^15 / 15 - y^16 / 16\r\n\r\n return res;\r\n }\r\n\r\n /**\r\n * @dev computes e ^ (x / FIXED_1) * FIXED_1\r\n * input range: 0 <= x <= OPT_EXP_MAX_VAL - 1\r\n * auto-generated via 'PrintFunctionOptimalExp.py'\r\n * Detailed description:\r\n * - Rewrite the input as a sum of binary exponents and a single residual r, as small as possible\r\n * - The exponentiation of each binary exponent is given (pre-calculated)\r\n * - The exponentiation of r is calculated via Taylor series for e^x, where x = r\r\n * - The exponentiation of the input is calculated by multiplying the intermediate results above\r\n * - For example: e^5.521692859 = e^(4 + 1 + 0.5 + 0.021692859) = e^4 * e^1 * e^0.5 * e^0.021692859\r\n */\r\n function optimalExp(uint256 x) internal pure returns (uint256) {\r\n uint256 res = 0;\r\n\r\n uint256 y;\r\n uint256 z;\r\n\r\n z = y = x % 0x10000000000000000000000000000000; // get the input modulo 2^(-3)\r\n z = z * y / FIXED_1; res += z * 0x10e1b3be415a0000; // add y^02 * (20! / 02!)\r\n z = z * y / FIXED_1; res += z * 0x05a0913f6b1e0000; // add y^03 * (20! / 03!)\r\n z = z * y / FIXED_1; res += z * 0x0168244fdac78000; // add y^04 * (20! / 04!)\r\n z = z * y / FIXED_1; res += z * 0x004807432bc18000; // add y^05 * (20! / 05!)\r\n z = z * y / FIXED_1; res += z * 0x000c0135dca04000; // add y^06 * (20! / 06!)\r\n z = z * y / FIXED_1; res += z * 0x0001b707b1cdc000; // add y^07 * (20! / 07!)\r\n z = z * y / FIXED_1; res += z * 0x000036e0f639b800; // add y^08 * (20! / 08!)\r\n z = z * y / FIXED_1; res += z * 0x00000618fee9f800; // add y^09 * (20! / 09!)\r\n z = z * y / FIXED_1; res += z * 0x0000009c197dcc00; // add y^10 * (20! / 10!)\r\n z = z * y / FIXED_1; res += z * 0x0000000e30dce400; // add y^11 * (20! / 11!)\r\n z = z * y / FIXED_1; res += z * 0x000000012ebd1300; // add y^12 * (20! / 12!)\r\n z = z * y / FIXED_1; res += z * 0x0000000017499f00; // add y^13 * (20! / 13!)\r\n z = z * y / FIXED_1; res += z * 0x0000000001a9d480; // add y^14 * (20! / 14!)\r\n z = z * y / FIXED_1; res += z * 0x00000000001c6380; // add y^15 * (20! / 15!)\r\n z = z * y / FIXED_1; res += z * 0x000000000001c638; // add y^16 * (20! / 16!)\r\n z = z * y / FIXED_1; res += z * 0x0000000000001ab8; // add y^17 * (20! / 17!)\r\n z = z * y / FIXED_1; res += z * 0x000000000000017c; // add y^18 * (20! / 18!)\r\n z = z * y / FIXED_1; res += z * 0x0000000000000014; // add y^19 * (20! / 19!)\r\n z = z * y / FIXED_1; res += z * 0x0000000000000001; // add y^20 * (20! / 20!)\r\n res = res / 0x21c3677c82b40000 + y + FIXED_1; // divide by 20! and then add y^1 / 1! + y^0 / 0!\r\n\r\n if ((x & 0x010000000000000000000000000000000) != 0) res = res * 0x1c3d6a24ed82218787d624d3e5eba95f9 / 0x18ebef9eac820ae8682b9793ac6d1e776; // multiply by e^2^(-3)\r\n if ((x & 0x020000000000000000000000000000000) != 0) res = res * 0x18ebef9eac820ae8682b9793ac6d1e778 / 0x1368b2fc6f9609fe7aceb46aa619baed4; // multiply by e^2^(-2)\r\n if ((x & 0x040000000000000000000000000000000) != 0) res = res * 0x1368b2fc6f9609fe7aceb46aa619baed5 / 0x0bc5ab1b16779be3575bd8f0520a9f21f; // multiply by e^2^(-1)\r\n if ((x & 0x080000000000000000000000000000000) != 0) res = res * 0x0bc5ab1b16779be3575bd8f0520a9f21e / 0x0454aaa8efe072e7f6ddbab84b40a55c9; // multiply by e^2^(+0)\r\n if ((x & 0x100000000000000000000000000000000) != 0) res = res * 0x0454aaa8efe072e7f6ddbab84b40a55c5 / 0x00960aadc109e7a3bf4578099615711ea; // multiply by e^2^(+1)\r\n if ((x & 0x200000000000000000000000000000000) != 0) res = res * 0x00960aadc109e7a3bf4578099615711d7 / 0x0002bf84208204f5977f9a8cf01fdce3d; // multiply by e^2^(+2)\r\n if ((x & 0x400000000000000000000000000000000) != 0) res = res * 0x0002bf84208204f5977f9a8cf01fdc307 / 0x0000003c6ab775dd0b95b4cbee7e65d11; // multiply by e^2^(+3)\r\n\r\n return res;\r\n }\r\n\r\n /**\r\n * @dev computes W(x / FIXED_1) / (x / FIXED_1) * FIXED_1\r\n */\r\n function lowerStake(uint256 _x) internal view returns (uint256) {\r\n if (_x <= LAMBERT_CONV_RADIUS)\r\n return lambertPos1(_x);\r\n if (_x <= LAMBERT_POS2_MAXVAL)\r\n return lambertPos2(_x);\r\n if (_x <= LAMBERT_POS3_MAXVAL)\r\n return lambertPos3(_x);\r\n require(false);\r\n }\r\n\r\n /**\r\n * @dev computes W(-x / FIXED_1) / (-x / FIXED_1) * FIXED_1\r\n */\r\n function higherStake(uint256 _x) internal pure returns (uint256) {\r\n if (_x <= LAMBERT_CONV_RADIUS)\r\n return lambertNeg1(_x);\r\n return FIXED_1 * FIXED_1 / _x;\r\n }\r\n\r\n /**\r\n * @dev computes W(x / FIXED_1) / (x / FIXED_1) * FIXED_1\r\n * input range: 1 <= x <= 1 / e * FIXED_1\r\n * auto-generated via 'PrintFunctionLambertPos1.py'\r\n */\r\n function lambertPos1(uint256 _x) internal pure returns (uint256) {\r\n uint256 xi = _x;\r\n uint256 res = (FIXED_1 - _x) * 0xde1bc4d19efcac82445da75b00000000; // x^(1-1) * (34! * 1^(1-1) / 1!) - x^(2-1) * (34! * 2^(2-1) / 2!)\r\n\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x00000000014d29a73a6e7b02c3668c7b0880000000; // add x^(03-1) * (34! * 03^(03-1) / 03!)\r\n xi = (xi * _x) / FIXED_1; res -= xi * 0x0000000002504a0cd9a7f7215b60f9be4800000000; // sub x^(04-1) * (34! * 04^(04-1) / 04!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x000000000484d0a1191c0ead267967c7a4a0000000; // add x^(05-1) * (34! * 05^(05-1) / 05!)\r\n xi = (xi * _x) / FIXED_1; res -= xi * 0x00000000095ec580d7e8427a4baf26a90a00000000; // sub x^(06-1) * (34! * 06^(06-1) / 06!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x000000001440b0be1615a47dba6e5b3b1f10000000; // add x^(07-1) * (34! * 07^(07-1) / 07!)\r\n xi = (xi * _x) / FIXED_1; res -= xi * 0x000000002d207601f46a99b4112418400000000000; // sub x^(08-1) * (34! * 08^(08-1) / 08!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0000000066ebaac4c37c622dd8288a7eb1b2000000; // add x^(09-1) * (34! * 09^(09-1) / 09!)\r\n xi = (xi * _x) / FIXED_1; res -= xi * 0x00000000ef17240135f7dbd43a1ba10cf200000000; // sub x^(10-1) * (34! * 10^(10-1) / 10!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0000000233c33c676a5eb2416094a87b3657000000; // add x^(11-1) * (34! * 11^(11-1) / 11!)\r\n xi = (xi * _x) / FIXED_1; res -= xi * 0x0000000541cde48bc0254bed49a9f8700000000000; // sub x^(12-1) * (34! * 12^(12-1) / 12!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0000000cae1fad2cdd4d4cb8d73abca0d19a400000; // add x^(13-1) * (34! * 13^(13-1) / 13!)\r\n xi = (xi * _x) / FIXED_1; res -= xi * 0x0000001edb2aa2f760d15c41ceedba956400000000; // sub x^(14-1) * (34! * 14^(14-1) / 14!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0000004ba8d20d2dabd386c9529659841a2e200000; // add x^(15-1) * (34! * 15^(15-1) / 15!)\r\n xi = (xi * _x) / FIXED_1; res -= xi * 0x000000bac08546b867cdaa20000000000000000000; // sub x^(16-1) * (34! * 16^(16-1) / 16!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x000001cfa8e70c03625b9db76c8ebf5bbf24820000; // add x^(17-1) * (34! * 17^(17-1) / 17!)\r\n xi = (xi * _x) / FIXED_1; res -= xi * 0x000004851d99f82060df265f3309b26f8200000000; // sub x^(18-1) * (34! * 18^(18-1) / 18!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x00000b550d19b129d270c44f6f55f027723cbb0000; // add x^(19-1) * (34! * 19^(19-1) / 19!)\r\n xi = (xi * _x) / FIXED_1; res -= xi * 0x00001c877dadc761dc272deb65d4b0000000000000; // sub x^(20-1) * (34! * 20^(20-1) / 20!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x000048178ece97479f33a77f2ad22a81b64406c000; // add x^(21-1) * (34! * 21^(21-1) / 21!)\r\n xi = (xi * _x) / FIXED_1; res -= xi * 0x0000b6ca8268b9d810fedf6695ef2f8a6c00000000; // sub x^(22-1) * (34! * 22^(22-1) / 22!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0001d0e76631a5b05d007b8cb72a7c7f11ec36e000; // add x^(23-1) * (34! * 23^(23-1) / 23!)\r\n xi = (xi * _x) / FIXED_1; res -= xi * 0x0004a1c37bd9f85fd9c6c780000000000000000000; // sub x^(24-1) * (34! * 24^(24-1) / 24!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x000bd8369f1b702bf491e2ebfcee08250313b65400; // add x^(25-1) * (34! * 25^(25-1) / 25!)\r\n xi = (xi * _x) / FIXED_1; res -= xi * 0x001e5c7c32a9f6c70ab2cb59d9225764d400000000; // sub x^(26-1) * (34! * 26^(26-1) / 26!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x004dff5820e165e910f95120a708e742496221e600; // add x^(27-1) * (34! * 27^(27-1) / 27!)\r\n xi = (xi * _x) / FIXED_1; res -= xi * 0x00c8c8f66db1fced378ee50e536000000000000000; // sub x^(28-1) * (34! * 28^(28-1) / 28!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0205db8dffff45bfa2938f128f599dbf16eb11d880; // add x^(29-1) * (34! * 29^(29-1) / 29!)\r\n xi = (xi * _x) / FIXED_1; res -= xi * 0x053a044ebd984351493e1786af38d39a0800000000; // sub x^(30-1) * (34! * 30^(30-1) / 30!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0d86dae2a4cc0f47633a544479735869b487b59c40; // add x^(31-1) * (34! * 31^(31-1) / 31!)\r\n xi = (xi * _x) / FIXED_1; res -= xi * 0x231000000000000000000000000000000000000000; // sub x^(32-1) * (34! * 32^(32-1) / 32!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x5b0485a76f6646c2039db1507cdd51b08649680822; // add x^(33-1) * (34! * 33^(33-1) / 33!)\r\n xi = (xi * _x) / FIXED_1; res -= xi * 0xec983c46c49545bc17efa6b5b0055e242200000000; // sub x^(34-1) * (34! * 34^(34-1) / 34!)\r\n\r\n return res / 0xde1bc4d19efcac82445da75b00000000; // divide by 34!\r\n }\r\n\r\n /**\r\n * @dev computes W(x / FIXED_1) / (x / FIXED_1) * FIXED_1\r\n * input range: LAMBERT_CONV_RADIUS + 1 <= x <= LAMBERT_POS2_MAXVAL\r\n */\r\n function lambertPos2(uint256 _x) internal view returns (uint256) {\r\n uint256 x = _x - LAMBERT_CONV_RADIUS - 1;\r\n uint256 i = x / LAMBERT_POS2_SAMPLE;\r\n uint256 a = LAMBERT_POS2_SAMPLE * i;\r\n uint256 b = LAMBERT_POS2_SAMPLE * (i + 1);\r\n uint256 c = lambertArray[i];\r\n uint256 d = lambertArray[i + 1];\r\n return (c * (b - x) + d * (x - a)) / LAMBERT_POS2_SAMPLE;\r\n }\r\n\r\n /**\r\n * @dev computes W(x / FIXED_1) / (x / FIXED_1) * FIXED_1\r\n * input range: LAMBERT_POS2_MAXVAL + 1 <= x <= LAMBERT_POS3_MAXVAL\r\n */\r\n function lambertPos3(uint256 _x) internal pure returns (uint256) {\r\n uint256 l1 = _x < OPT_LOG_MAX_VAL ? optimalLog(_x) : generalLog(_x);\r\n uint256 l2 = l1 < OPT_LOG_MAX_VAL ? optimalLog(l1) : generalLog(l1);\r\n return (l1 - l2 + l2 * FIXED_1 / l1) * FIXED_1 / _x;\r\n }\r\n\r\n /**\r\n * @dev computes W(-x / FIXED_1) / (-x / FIXED_1) * FIXED_1\r\n * input range: 1 <= x <= 1 / e * FIXED_1\r\n * auto-generated via 'PrintFunctionLambertNeg1.py'\r\n */\r\n function lambertNeg1(uint256 _x) internal pure returns (uint256) {\r\n uint256 xi = _x;\r\n uint256 res = 0;\r\n\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x00000000014d29a73a6e7b02c3668c7b0880000000; // add x^(03-1) * (34! * 03^(03-1) / 03!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0000000002504a0cd9a7f7215b60f9be4800000000; // add x^(04-1) * (34! * 04^(04-1) / 04!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x000000000484d0a1191c0ead267967c7a4a0000000; // add x^(05-1) * (34! * 05^(05-1) / 05!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x00000000095ec580d7e8427a4baf26a90a00000000; // add x^(06-1) * (34! * 06^(06-1) / 06!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x000000001440b0be1615a47dba6e5b3b1f10000000; // add x^(07-1) * (34! * 07^(07-1) / 07!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x000000002d207601f46a99b4112418400000000000; // add x^(08-1) * (34! * 08^(08-1) / 08!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0000000066ebaac4c37c622dd8288a7eb1b2000000; // add x^(09-1) * (34! * 09^(09-1) / 09!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x00000000ef17240135f7dbd43a1ba10cf200000000; // add x^(10-1) * (34! * 10^(10-1) / 10!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0000000233c33c676a5eb2416094a87b3657000000; // add x^(11-1) * (34! * 11^(11-1) / 11!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0000000541cde48bc0254bed49a9f8700000000000; // add x^(12-1) * (34! * 12^(12-1) / 12!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0000000cae1fad2cdd4d4cb8d73abca0d19a400000; // add x^(13-1) * (34! * 13^(13-1) / 13!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0000001edb2aa2f760d15c41ceedba956400000000; // add x^(14-1) * (34! * 14^(14-1) / 14!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0000004ba8d20d2dabd386c9529659841a2e200000; // add x^(15-1) * (34! * 15^(15-1) / 15!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x000000bac08546b867cdaa20000000000000000000; // add x^(16-1) * (34! * 16^(16-1) / 16!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x000001cfa8e70c03625b9db76c8ebf5bbf24820000; // add x^(17-1) * (34! * 17^(17-1) / 17!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x000004851d99f82060df265f3309b26f8200000000; // add x^(18-1) * (34! * 18^(18-1) / 18!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x00000b550d19b129d270c44f6f55f027723cbb0000; // add x^(19-1) * (34! * 19^(19-1) / 19!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x00001c877dadc761dc272deb65d4b0000000000000; // add x^(20-1) * (34! * 20^(20-1) / 20!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x000048178ece97479f33a77f2ad22a81b64406c000; // add x^(21-1) * (34! * 21^(21-1) / 21!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0000b6ca8268b9d810fedf6695ef2f8a6c00000000; // add x^(22-1) * (34! * 22^(22-1) / 22!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0001d0e76631a5b05d007b8cb72a7c7f11ec36e000; // add x^(23-1) * (34! * 23^(23-1) / 23!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0004a1c37bd9f85fd9c6c780000000000000000000; // add x^(24-1) * (34! * 24^(24-1) / 24!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x000bd8369f1b702bf491e2ebfcee08250313b65400; // add x^(25-1) * (34! * 25^(25-1) / 25!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x001e5c7c32a9f6c70ab2cb59d9225764d400000000; // add x^(26-1) * (34! * 26^(26-1) / 26!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x004dff5820e165e910f95120a708e742496221e600; // add x^(27-1) * (34! * 27^(27-1) / 27!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x00c8c8f66db1fced378ee50e536000000000000000; // add x^(28-1) * (34! * 28^(28-1) / 28!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0205db8dffff45bfa2938f128f599dbf16eb11d880; // add x^(29-1) * (34! * 29^(29-1) / 29!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x053a044ebd984351493e1786af38d39a0800000000; // add x^(30-1) * (34! * 30^(30-1) / 30!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x0d86dae2a4cc0f47633a544479735869b487b59c40; // add x^(31-1) * (34! * 31^(31-1) / 31!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x231000000000000000000000000000000000000000; // add x^(32-1) * (34! * 32^(32-1) / 32!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0x5b0485a76f6646c2039db1507cdd51b08649680822; // add x^(33-1) * (34! * 33^(33-1) / 33!)\r\n xi = (xi * _x) / FIXED_1; res += xi * 0xec983c46c49545bc17efa6b5b0055e242200000000; // add x^(34-1) * (34! * 34^(34-1) / 34!)\r\n\r\n return res / 0xde1bc4d19efcac82445da75b00000000 + _x + FIXED_1; // divide by 34! and then add x^(2-1) * (34! * 2^(2-1) / 2!) + x^(1-1) * (34! * 1^(1-1) / 1!)\r\n }\r\n\r\n /**\r\n * @dev computes the weights based on \"W(log(hi / lo) * tq / rp) * tq / rp\", where \"W\" is a variation of the Lambert W function.\r\n */\r\n function balancedWeightsByStake(uint256 _hi, uint256 _lo, uint256 _tq, uint256 _rp, bool _lowerStake) internal view returns (uint32, uint32) {\r\n (_tq, _rp) = safeFactors(_tq, _rp);\r\n uint256 f = _hi.mul(FIXED_1) / _lo;\r\n uint256 g = f < OPT_LOG_MAX_VAL ? optimalLog(f) : generalLog(f);\r\n uint256 x = g.mul(_tq) / _rp;\r\n uint256 y = _lowerStake ? lowerStake(x) : higherStake(x);\r\n return normalizedWeights(y.mul(_tq), _rp.mul(FIXED_1));\r\n }\r\n\r\n /**\r\n * @dev reduces \"a\" and \"b\" while maintaining their ratio.\r\n */\r\n function safeFactors(uint256 _a, uint256 _b) internal pure returns (uint256, uint256) {\r\n if (_a <= FIXED_2 && _b <= FIXED_2)\r\n return (_a, _b);\r\n if (_a < FIXED_2)\r\n return (_a * FIXED_2 / _b, FIXED_2);\r\n if (_b < FIXED_2)\r\n return (FIXED_2, _b * FIXED_2 / _a);\r\n uint256 c = _a > _b ? _a : _b;\r\n uint256 n = floorLog2(c / FIXED_1);\r\n return (_a >> n, _b >> n);\r\n }\r\n\r\n /**\r\n * @dev computes \"MAX_WEIGHT * a / (a + b)\" and \"MAX_WEIGHT * b / (a + b)\".\r\n */\r\n function normalizedWeights(uint256 _a, uint256 _b) internal pure returns (uint32, uint32) {\r\n if (_a <= _b)\r\n return accurateWeights(_a, _b);\r\n (uint32 y, uint32 x) = accurateWeights(_b, _a);\r\n return (x, y);\r\n }\r\n\r\n /**\r\n * @dev computes \"MAX_WEIGHT * a / (a + b)\" and \"MAX_WEIGHT * b / (a + b)\", assuming that \"a <= b\".\r\n */\r\n function accurateWeights(uint256 _a, uint256 _b) internal pure returns (uint32, uint32) {\r\n if (_a > MAX_UNF_WEIGHT) {\r\n uint256 c = _a / (MAX_UNF_WEIGHT + 1) + 1;\r\n _a /= c;\r\n _b /= c;\r\n }\r\n uint256 x = roundDiv(_a * MAX_WEIGHT, _a.add(_b));\r\n uint256 y = MAX_WEIGHT - x;\r\n return (uint32(x), uint32(y));\r\n }\r\n\r\n /**\r\n * @dev computes the nearest integer to a given quotient without overflowing or underflowing.\r\n */\r\n function roundDiv(uint256 _n, uint256 _d) internal pure returns (uint256) {\r\n return _n / _d + _n % _d / (_d - _d / 2);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function calculatePurchaseReturn(uint256 _supply,\r\n uint256 _reserveBalance,\r\n uint32 _reserveWeight,\r\n uint256 _amount)\r\n public view returns (uint256)\r\n {\r\n return purchaseTargetAmount(_supply, _reserveBalance, _reserveWeight, _amount);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function calculateSaleReturn(uint256 _supply,\r\n uint256 _reserveBalance,\r\n uint32 _reserveWeight,\r\n uint256 _amount)\r\n public view returns (uint256)\r\n {\r\n return saleTargetAmount(_supply, _reserveBalance, _reserveWeight, _amount);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function calculateCrossReserveReturn(uint256 _sourceReserveBalance,\r\n uint32 _sourceReserveWeight,\r\n uint256 _targetReserveBalance,\r\n uint32 _targetReserveWeight,\r\n uint256 _amount)\r\n public view returns (uint256)\r\n {\r\n return crossReserveTargetAmount(_sourceReserveBalance, _sourceReserveWeight, _targetReserveBalance, _targetReserveWeight, _amount);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function calculateCrossConnectorReturn(uint256 _sourceReserveBalance,\r\n uint32 _sourceReserveWeight,\r\n uint256 _targetReserveBalance,\r\n uint32 _targetReserveWeight,\r\n uint256 _amount)\r\n public view returns (uint256)\r\n {\r\n return crossReserveTargetAmount(_sourceReserveBalance, _sourceReserveWeight, _targetReserveBalance, _targetReserveWeight, _amount);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function calculateFundCost(uint256 _supply,\r\n uint256 _reserveBalance,\r\n uint32 _reserveRatio,\r\n uint256 _amount)\r\n public view returns (uint256)\r\n {\r\n return fundCost(_supply, _reserveBalance, _reserveRatio, _amount);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function calculateLiquidateReturn(uint256 _supply,\r\n uint256 _reserveBalance,\r\n uint32 _reserveRatio,\r\n uint256 _amount)\r\n public view returns (uint256)\r\n {\r\n return liquidateReserveAmount(_supply, _reserveBalance, _reserveRatio, _amount);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function purchaseRate(uint256 _supply,\r\n uint256 _reserveBalance,\r\n uint32 _reserveWeight,\r\n uint256 _amount)\r\n public view returns (uint256)\r\n {\r\n return purchaseTargetAmount(_supply, _reserveBalance, _reserveWeight, _amount);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function saleRate(uint256 _supply,\r\n uint256 _reserveBalance,\r\n uint32 _reserveWeight,\r\n uint256 _amount)\r\n public view returns (uint256)\r\n {\r\n return saleTargetAmount(_supply, _reserveBalance, _reserveWeight, _amount);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function crossReserveRate(uint256 _sourceReserveBalance,\r\n uint32 _sourceReserveWeight,\r\n uint256 _targetReserveBalance,\r\n uint32 _targetReserveWeight,\r\n uint256 _amount)\r\n public view returns (uint256)\r\n {\r\n return crossReserveTargetAmount(_sourceReserveBalance, _sourceReserveWeight, _targetReserveBalance, _targetReserveWeight, _amount);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function liquidateRate(uint256 _supply,\r\n uint256 _reserveBalance,\r\n uint32 _reserveRatio,\r\n uint256 _amount)\r\n public view returns (uint256)\r\n {\r\n return liquidateReserveAmount(_supply, _reserveBalance, _reserveRatio, _amount);\r\n }\r\n}\r\n",
+ "sourcePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/BancorFormula.sol",
+ "ast": {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/BancorFormula.sol",
+ "exportedSymbols": {
+ "BancorFormula": [
+ 8977
+ ]
+ },
+ "id": 8978,
+ "license": "SEE LICENSE IN LICENSE",
+ "nodeType": "SourceUnit",
+ "nodes": [
+ {
+ "id": 3564,
+ "literals": [
+ "solidity",
+ "0.6",
+ ".12"
+ ],
+ "nodeType": "PragmaDirective",
+ "src": "52:23:7"
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IBancorFormula.sol",
+ "file": "./interfaces/IBancorFormula.sol",
+ "id": 3565,
+ "nodeType": "ImportDirective",
+ "scope": 8978,
+ "sourceUnit": 13178,
+ "src": "77:41:7",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/SafeMath.sol",
+ "file": "../utility/SafeMath.sol",
+ "id": 3566,
+ "nodeType": "ImportDirective",
+ "scope": 8978,
+ "sourceUnit": 22355,
+ "src": "120:33:7",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "abstract": false,
+ "baseContracts": [
+ {
+ "arguments": null,
+ "baseName": {
+ "contractScope": null,
+ "id": 3567,
+ "name": "IBancorFormula",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13177,
+ "src": "183:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorFormula_$13177",
+ "typeString": "contract IBancorFormula"
+ }
+ },
+ "id": 3568,
+ "nodeType": "InheritanceSpecifier",
+ "src": "183:14:7"
+ }
+ ],
+ "contractDependencies": [
+ 13177
+ ],
+ "contractKind": "contract",
+ "documentation": null,
+ "fullyImplemented": true,
+ "id": 8977,
+ "linearizedBaseContracts": [
+ 8977,
+ 13177
+ ],
+ "name": "BancorFormula",
+ "nodeType": "ContractDefinition",
+ "nodes": [
+ {
+ "id": 3571,
+ "libraryName": {
+ "contractScope": null,
+ "id": 3569,
+ "name": "SafeMath",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 22354,
+ "src": "211:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_SafeMath_$22354",
+ "typeString": "library SafeMath"
+ }
+ },
+ "nodeType": "UsingForDirective",
+ "src": "205:27:7",
+ "typeName": {
+ "id": 3570,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "224:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ },
+ {
+ "constant": true,
+ "id": 3574,
+ "mutability": "constant",
+ "name": "ONE",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "240:32:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3572,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "240:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 3573,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "271:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3577,
+ "mutability": "constant",
+ "name": "MAX_WEIGHT",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "279:44:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 3575,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "279:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "31303030303030",
+ "id": 3576,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "316:7:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1000000_by_1",
+ "typeString": "int_const 1000000"
+ },
+ "value": "1000000"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3580,
+ "mutability": "constant",
+ "name": "MIN_PRECISION",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "330:41:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 3578,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "330:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "3332",
+ "id": 3579,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "369:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_32_by_1",
+ "typeString": "int_const 32"
+ },
+ "value": "32"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3583,
+ "mutability": "constant",
+ "name": "MAX_PRECISION",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "378:42:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 3581,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "378:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "313237",
+ "id": 3582,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "417:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_127_by_1",
+ "typeString": "int_const 127"
+ },
+ "value": "127"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3586,
+ "mutability": "constant",
+ "name": "FIXED_1",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "484:70:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3584,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "484:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "3078303830303030303030303030303030303030303030303030303030303030303030",
+ "id": 3585,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "519:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_170141183460469231731687303715884105728_by_1",
+ "typeString": "int_const 1701...(31 digits omitted)...5728"
+ },
+ "value": "0x080000000000000000000000000000000"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3589,
+ "mutability": "constant",
+ "name": "FIXED_2",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "561:70:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3587,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "561:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "3078313030303030303030303030303030303030303030303030303030303030303030",
+ "id": 3588,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "596:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_340282366920938463463374607431768211456_by_1",
+ "typeString": "int_const 3402...(31 digits omitted)...1456"
+ },
+ "value": "0x100000000000000000000000000000000"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3592,
+ "mutability": "constant",
+ "name": "MAX_NUM",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "638:70:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3590,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "638:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "3078323030303030303030303030303030303030303030303030303030303030303030",
+ "id": 3591,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "673:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_680564733841876926926749214863536422912_by_1",
+ "typeString": "int_const 6805...(31 digits omitted)...2912"
+ },
+ "value": "0x200000000000000000000000000000000"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3595,
+ "mutability": "constant",
+ "name": "LN2_NUMERATOR",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "772:76:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3593,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "772:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "307833663830666530336638306665303366383066653033663830666530336638",
+ "id": 3594,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "815:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_5275695611177340518812009417546793976_by_1",
+ "typeString": "int_const 5275...(29 digits omitted)...3976"
+ },
+ "value": "0x3f80fe03f80fe03f80fe03f80fe03f8"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3598,
+ "mutability": "constant",
+ "name": "LN2_DENOMINATOR",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "855:76:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3596,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "855:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "307835623964653164313062663431303364363437623039353538393762613830",
+ "id": 3597,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "898:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_7611219895485218073587121647846406784_by_1",
+ "typeString": "int_const 7611...(29 digits omitted)...6784"
+ },
+ "value": "0x5b9de1d10bf4103d647b0955897ba80"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3601,
+ "mutability": "constant",
+ "name": "OPT_LOG_MAX_VAL",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "1029:78:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3599,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1029:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "3078313562663061386231343537363935333535666238616334303465376137396533",
+ "id": 3600,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "1072:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_462491687273110168575455517921668397539_by_1",
+ "typeString": "int_const 4624...(31 digits omitted)...7539"
+ },
+ "value": "0x15bf0a8b1457695355fb8ac404e7a79e3"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3604,
+ "mutability": "constant",
+ "name": "OPT_EXP_MAX_VAL",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "1114:78:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3602,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1114:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "3078383030303030303030303030303030303030303030303030303030303030303030",
+ "id": 3603,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "1157:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2722258935367507707706996859454145691648_by_1",
+ "typeString": "int_const 2722...(32 digits omitted)...1648"
+ },
+ "value": "0x800000000000000000000000000000000"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3607,
+ "mutability": "constant",
+ "name": "LAMBERT_CONV_RADIUS",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "1253:83:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3605,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1253:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "307830303266313661633663353964653666386435643666363363313438326137633836",
+ "id": 3606,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "1300:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_62591443491685266058625363149075414150_by_1",
+ "typeString": "int_const 6259...(30 digits omitted)...4150"
+ },
+ "value": "0x002f16ac6c59de6f8d5d6f63c1482a7c86"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3610,
+ "mutability": "constant",
+ "name": "LAMBERT_POS2_SAMPLE",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "1343:83:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3608,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1343:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "307830303033303630633138333036306331383330363063313833303630633138333036",
+ "id": 3609,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "1390:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4019083073869351930669778827934270214_by_1",
+ "typeString": "int_const 4019...(29 digits omitted)...0214"
+ },
+ "value": "0x0003060c183060c183060c183060c18306"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3613,
+ "mutability": "constant",
+ "name": "LAMBERT_POS2_MAXVAL",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "1433:83:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3611,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1433:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "307830316166313661633663353964653666386435643666363363313438326137633830",
+ "id": 3612,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "1480:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_573014993873092961253687274296727731328_by_1",
+ "typeString": "int_const 5730...(31 digits omitted)...1328"
+ },
+ "value": "0x01af16ac6c59de6f8d5d6f63c1482a7c80"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3616,
+ "mutability": "constant",
+ "name": "LAMBERT_POS3_MAXVAL",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "1523:83:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3614,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1523:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "307836623232643433653732633332363533396363656565663862623438663235356666",
+ "id": 3615,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "1570:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_36456509045932913977692090597752865707519_by_1",
+ "typeString": "int_const 3645...(33 digits omitted)...7519"
+ },
+ "value": "0x6b22d43e72c326539cceeef8bb48f255ff"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3619,
+ "mutability": "constant",
+ "name": "MAX_UNF_WEIGHT",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "1666:104:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3617,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1666:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "3078313063366637613062356564386433366234633766333439333835383336323166616663386230303739613238333464323666613366636339656139",
+ "id": 3618,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "1708:62:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_115792089237316195423570985008687907853269984665640564039457584007913129_by_1",
+ "typeString": "int_const 1157...(64 digits omitted)...3129"
+ },
+ "value": "0x10c6f7a0b5ed8d36b4c7f34938583621fafc8b0079a2834d26fa3fcc9ea9"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": false,
+ "id": 3623,
+ "mutability": "mutable",
+ "name": "maxExpArray",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "1828:32:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 3620,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1828:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3622,
+ "length": {
+ "argumentTypes": null,
+ "hexValue": "313238",
+ "id": 3621,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "1836:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_128_by_1",
+ "typeString": "int_const 128"
+ },
+ "value": "128"
+ },
+ "nodeType": "ArrayTypeName",
+ "src": "1828:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage_ptr",
+ "typeString": "uint256[128]"
+ }
+ },
+ "value": null,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 4202,
+ "nodeType": "Block",
+ "src": "1902:8456:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3630,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3626,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4025:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3628,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3332",
+ "id": 3627,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4038:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_32_by_1",
+ "typeString": "int_const 32"
+ },
+ "value": "32"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4025:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831633335666564643134666666666666666666666666666666666666666666666666",
+ "id": 3629,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4044:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_9599678685041259184274752310158947254271_by_1",
+ "typeString": "int_const 9599...(32 digits omitted)...4271"
+ },
+ "value": "0x1c35fedd14ffffffffffffffffffffffff"
+ },
+ "src": "4025:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3631,
+ "nodeType": "ExpressionStatement",
+ "src": "4025:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3636,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3632,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4091:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3634,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3333",
+ "id": 3633,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4104:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_33_by_1",
+ "typeString": "int_const 33"
+ },
+ "value": "33"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4091:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831623063653433623332336666666666666666666666666666666666666666666666",
+ "id": 3635,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4110:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_9204759687141885226475603015507577405439_by_1",
+ "typeString": "int_const 9204...(32 digits omitted)...5439"
+ },
+ "value": "0x1b0ce43b323fffffffffffffffffffffff"
+ },
+ "src": "4091:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3637,
+ "nodeType": "ExpressionStatement",
+ "src": "4091:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3642,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3638,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4157:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3640,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3334",
+ "id": 3639,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4170:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_34_by_1",
+ "typeString": "int_const 34"
+ },
+ "value": "34"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4157:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831396630303238656331666666666666666666666666666666666666666666666666",
+ "id": 3641,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4176:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_8826087172077985712041017634911355404287_by_1",
+ "typeString": "int_const 8826...(32 digits omitted)...4287"
+ },
+ "value": "0x19f0028ec1ffffffffffffffffffffffff"
+ },
+ "src": "4157:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3643,
+ "nodeType": "ExpressionStatement",
+ "src": "4157:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3648,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3644,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4223:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3646,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3335",
+ "id": 3645,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4236:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_35_by_1",
+ "typeString": "int_const 35"
+ },
+ "value": "35"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4223:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831386465643931663065376666666666666666666666666666666666666666666666",
+ "id": 3647,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4242:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_8462992779488582574159642900919291478015_by_1",
+ "typeString": "int_const 8462...(32 digits omitted)...8015"
+ },
+ "value": "0x18ded91f0e7fffffffffffffffffffffff"
+ },
+ "src": "4223:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3649,
+ "nodeType": "ExpressionStatement",
+ "src": "4223:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3654,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3650,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4289:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3652,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3336",
+ "id": 3651,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4302:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_36_by_1",
+ "typeString": "int_const 36"
+ },
+ "value": "36"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4289:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831376438656337663034313766666666666666666666666666666666666666666666",
+ "id": 3653,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4308:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_8114835644520100661580084966409403105279_by_1",
+ "typeString": "int_const 8114...(32 digits omitted)...5279"
+ },
+ "value": "0x17d8ec7f0417ffffffffffffffffffffff"
+ },
+ "src": "4289:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3655,
+ "nodeType": "ExpressionStatement",
+ "src": "4289:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3660,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3656,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4355:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3658,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3337",
+ "id": 3657,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4368:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_37_by_1",
+ "typeString": "int_const 37"
+ },
+ "value": "37"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4355:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831366464633635353663646266666666666666666666666666666666666666666666",
+ "id": 3659,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4374:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_7781001266736647064069662172832600162303_by_1",
+ "typeString": "int_const 7781...(32 digits omitted)...2303"
+ },
+ "value": "0x16ddc6556cdbffffffffffffffffffffff"
+ },
+ "src": "4355:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3661,
+ "nodeType": "ExpressionStatement",
+ "src": "4355:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3666,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3662,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4421:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3664,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3338",
+ "id": 3663,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4434:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_38_by_1",
+ "typeString": "int_const 38"
+ },
+ "value": "38"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4421:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831356563663532373736613166666666666666666666666666666666666666666666",
+ "id": 3665,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4440:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_7460900425488323202194551465008353509375_by_1",
+ "typeString": "int_const 7460...(32 digits omitted)...9375"
+ },
+ "value": "0x15ecf52776a1ffffffffffffffffffffff"
+ },
+ "src": "4421:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3667,
+ "nodeType": "ExpressionStatement",
+ "src": "4421:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3672,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3668,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4487:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3670,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3339",
+ "id": 3669,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4500:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_39_by_1",
+ "typeString": "int_const 39"
+ },
+ "value": "39"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4487:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831353036306332353663623266666666666666666666666666666666666666666666",
+ "id": 3671,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4506:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_7153968139937914349310206877837545177087_by_1",
+ "typeString": "int_const 7153...(32 digits omitted)...7087"
+ },
+ "value": "0x15060c256cb2ffffffffffffffffffffff"
+ },
+ "src": "4487:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3673,
+ "nodeType": "ExpressionStatement",
+ "src": "4487:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3678,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3674,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4553:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3676,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3430",
+ "id": 3675,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4566:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_40_by_1",
+ "typeString": "int_const 40"
+ },
+ "value": "40"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4553:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831343238613266393864373266666666666666666666666666666666666666666666",
+ "id": 3677,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4572:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6859662671868001546166128217910528704511_by_1",
+ "typeString": "int_const 6859...(32 digits omitted)...4511"
+ },
+ "value": "0x1428a2f98d72ffffffffffffffffffffff"
+ },
+ "src": "4553:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3679,
+ "nodeType": "ExpressionStatement",
+ "src": "4553:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3684,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3680,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4619:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3682,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3431",
+ "id": 3681,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4632:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_41_by_1",
+ "typeString": "int_const 41"
+ },
+ "value": "41"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4619:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831333534353539386535633233666666666666666666666666666666666666666666",
+ "id": 3683,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4638:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6577464569506365633454696454958677491711_by_1",
+ "typeString": "int_const 6577...(32 digits omitted)...1711"
+ },
+ "value": "0x13545598e5c23fffffffffffffffffffff"
+ },
+ "src": "4619:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3685,
+ "nodeType": "ExpressionStatement",
+ "src": "4619:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3690,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3686,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4685:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3688,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3432",
+ "id": 3687,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4698:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_42_by_1",
+ "typeString": "int_const 42"
+ },
+ "value": "42"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4685:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831323838633431363163653164666666666666666666666666666666666666666666",
+ "id": 3689,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4704:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6306875750689218484600399768107450630143_by_1",
+ "typeString": "int_const 6306...(32 digits omitted)...0143"
+ },
+ "value": "0x1288c4161ce1dfffffffffffffffffffff"
+ },
+ "src": "4685:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3691,
+ "nodeType": "ExpressionStatement",
+ "src": "4685:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3696,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3692,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4751:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3694,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3433",
+ "id": 3693,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4764:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_43_by_1",
+ "typeString": "int_const 43"
+ },
+ "value": "43"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4751:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831316335393237363163363636666666666666666666666666666666666666666666",
+ "id": 3695,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4770:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6047418623741353042663269283551730728959_by_1",
+ "typeString": "int_const 6047...(32 digits omitted)...8959"
+ },
+ "value": "0x11c592761c666fffffffffffffffffffff"
+ },
+ "src": "4751:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3697,
+ "nodeType": "ExpressionStatement",
+ "src": "4751:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3702,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3698,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4817:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3700,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3434",
+ "id": 3699,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4830:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_44_by_1",
+ "typeString": "int_const 44"
+ },
+ "value": "44"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4817:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831313061363838363830613735376666666666666666666666666666666666666666",
+ "id": 3701,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4836:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_5798635244522972732941736303310812479487_by_1",
+ "typeString": "int_const 5798...(32 digits omitted)...9487"
+ },
+ "value": "0x110a688680a757ffffffffffffffffffff"
+ },
+ "src": "4817:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3703,
+ "nodeType": "ExpressionStatement",
+ "src": "4817:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3708,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3704,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4883:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3706,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3435",
+ "id": 3705,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4896:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_45_by_1",
+ "typeString": "int_const 45"
+ },
+ "value": "45"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4883:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831303536663162356265646637376666666666666666666666666666666666666666",
+ "id": 3707,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4902:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_5560086508154074440893281558760167309311_by_1",
+ "typeString": "int_const 5560...(32 digits omitted)...9311"
+ },
+ "value": "0x1056f1b5bedf77ffffffffffffffffffff"
+ },
+ "src": "4883:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3709,
+ "nodeType": "ExpressionStatement",
+ "src": "4883:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3714,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3710,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4949:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3712,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3436",
+ "id": 3711,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4962:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_46_by_1",
+ "typeString": "int_const 46"
+ },
+ "value": "46"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4949:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830666161646365636565666638626666666666666666666666666666666666666666",
+ "id": 3713,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4968:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_5331351373990447379730864460340651884543_by_1",
+ "typeString": "int_const 5331...(32 digits omitted)...4543"
+ },
+ "value": "0x0faadceceeff8bffffffffffffffffffff"
+ },
+ "src": "4949:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3715,
+ "nodeType": "ExpressionStatement",
+ "src": "4949:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3720,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3716,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5015:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3718,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3437",
+ "id": 3717,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5028:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_47_by_1",
+ "typeString": "int_const 47"
+ },
+ "value": "47"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5015:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830663035646336623237656461646666666666666666666666666666666666666666",
+ "id": 3719,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5034:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_5112026122483163422598731111238626967551_by_1",
+ "typeString": "int_const 5112...(32 digits omitted)...7551"
+ },
+ "value": "0x0f05dc6b27edadffffffffffffffffffff"
+ },
+ "src": "5015:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3721,
+ "nodeType": "ExpressionStatement",
+ "src": "5015:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3726,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3722,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5081:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3724,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3438",
+ "id": 3723,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5094:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_48_by_1",
+ "typeString": "int_const 48"
+ },
+ "value": "48"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5081:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830653637613561323564613431303766666666666666666666666666666666666666",
+ "id": 3725,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5100:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4901723642609993464238960471454494228479_by_1",
+ "typeString": "int_const 4901...(32 digits omitted)...8479"
+ },
+ "value": "0x0e67a5a25da4107fffffffffffffffffff"
+ },
+ "src": "5081:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3727,
+ "nodeType": "ExpressionStatement",
+ "src": "5081:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3732,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3728,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5147:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3730,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3439",
+ "id": 3729,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5160:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_49_by_1",
+ "typeString": "int_const 49"
+ },
+ "value": "49"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5147:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830646366663131356231346565646666666666666666666666666666666666666666",
+ "id": 3731,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5166:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4700072748620998500994433661760029327359_by_1",
+ "typeString": "int_const 4700...(32 digits omitted)...7359"
+ },
+ "value": "0x0dcff115b14eedffffffffffffffffffff"
+ },
+ "src": "5147:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3733,
+ "nodeType": "ExpressionStatement",
+ "src": "5147:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3738,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3734,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5213:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3736,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3530",
+ "id": 3735,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5226:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_50_by_1",
+ "typeString": "int_const 50"
+ },
+ "value": "50"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5213:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830643365376133393234333132333966666666666666666666666666666666666666",
+ "id": 3737,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5232:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4506717524892375150236886652795301658623_by_1",
+ "typeString": "int_const 4506...(32 digits omitted)...8623"
+ },
+ "value": "0x0d3e7a392431239fffffffffffffffffff"
+ },
+ "src": "5213:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3739,
+ "nodeType": "ExpressionStatement",
+ "src": "5213:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3744,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3740,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5279:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3742,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3531",
+ "id": 3741,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5292:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_51_by_1",
+ "typeString": "int_const 51"
+ },
+ "value": "51"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5279:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830636232666635323965623731653466666666666666666666666666666666666666",
+ "id": 3743,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5298:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4321316697732212547034601541953113817087_by_1",
+ "typeString": "int_const 4321...(32 digits omitted)...7087"
+ },
+ "value": "0x0cb2ff529eb71e4fffffffffffffffffff"
+ },
+ "src": "5279:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3745,
+ "nodeType": "ExpressionStatement",
+ "src": "5279:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3750,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3746,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5345:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3748,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3532",
+ "id": 3747,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5358:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_52_by_1",
+ "typeString": "int_const 52"
+ },
+ "value": "52"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5345:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830633264343135633364623937346166666666666666666666666666666666666666",
+ "id": 3749,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5364:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4143543033029384782309349805264440655871_by_1",
+ "typeString": "int_const 4143...(32 digits omitted)...5871"
+ },
+ "value": "0x0c2d415c3db974afffffffffffffffffff"
+ },
+ "src": "5345:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3751,
+ "nodeType": "ExpressionStatement",
+ "src": "5345:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3756,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3752,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5411:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3754,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3533",
+ "id": 3753,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5424:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_53_by_1",
+ "typeString": "int_const 53"
+ },
+ "value": "53"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5411:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830626164303365376438383366363962666666666666666666666666666666666666",
+ "id": 3755,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5430:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3973082758682431363936722477132055314431_by_1",
+ "typeString": "int_const 3973...(32 digits omitted)...4431"
+ },
+ "value": "0x0bad03e7d883f69bffffffffffffffffff"
+ },
+ "src": "5411:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3757,
+ "nodeType": "ExpressionStatement",
+ "src": "5411:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3762,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3758,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5477:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3760,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3534",
+ "id": 3759,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5490:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_54_by_1",
+ "typeString": "int_const 54"
+ },
+ "value": "54"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5477:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830623332306430336232633334336435666666666666666666666666666666666666",
+ "id": 3761,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5496:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3809635010789003168527049097368437784575_by_1",
+ "typeString": "int_const 3809...(32 digits omitted)...4575"
+ },
+ "value": "0x0b320d03b2c343d5ffffffffffffffffff"
+ },
+ "src": "5477:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3763,
+ "nodeType": "ExpressionStatement",
+ "src": "5477:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3768,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3764,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5543:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3766,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3535",
+ "id": 3765,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5556:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_55_by_1",
+ "typeString": "int_const 55"
+ },
+ "value": "55"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5543:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830616263323532303465303238323864666666666666666666666666666666666666",
+ "id": 3767,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5562:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3652911302618395401280222488042819026943_by_1",
+ "typeString": "int_const 3652...(32 digits omitted)...6943"
+ },
+ "value": "0x0abc25204e02828dffffffffffffffffff"
+ },
+ "src": "5543:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3769,
+ "nodeType": "ExpressionStatement",
+ "src": "5543:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3774,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3770,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5609:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3772,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3536",
+ "id": 3771,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5622:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_56_by_1",
+ "typeString": "int_const 56"
+ },
+ "value": "56"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5609:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830613462313666373465653462623230376666666666666666666666666666666666",
+ "id": 3773,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5628:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3502635015429898674229017626613836152831_by_1",
+ "typeString": "int_const 3502...(32 digits omitted)...2831"
+ },
+ "value": "0x0a4b16f74ee4bb207fffffffffffffffff"
+ },
+ "src": "5609:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3775,
+ "nodeType": "ExpressionStatement",
+ "src": "5609:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3780,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3776,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5675:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3778,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3537",
+ "id": 3777,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5688:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_57_by_1",
+ "typeString": "int_const 57"
+ },
+ "value": "57"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5675:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830396465616637333661633166353639666666666666666666666666666666666666",
+ "id": 3779,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5694:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3358540910238258030536300376569398951935_by_1",
+ "typeString": "int_const 3358...(32 digits omitted)...1935"
+ },
+ "value": "0x09deaf736ac1f569ffffffffffffffffff"
+ },
+ "src": "5675:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3781,
+ "nodeType": "ExpressionStatement",
+ "src": "5675:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3786,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3782,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5741:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3784,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3538",
+ "id": 3783,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5754:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_58_by_1",
+ "typeString": "int_const 58"
+ },
+ "value": "58"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5741:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830393736626439393532633761613935376666666666666666666666666666666666",
+ "id": 3785,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5760:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3220374659664501751807634855053158776831_by_1",
+ "typeString": "int_const 3220...(32 digits omitted)...6831"
+ },
+ "value": "0x0976bd9952c7aa957fffffffffffffffff"
+ },
+ "src": "5741:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3787,
+ "nodeType": "ExpressionStatement",
+ "src": "5741:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3792,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3788,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5807:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3790,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3539",
+ "id": 3789,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5820:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_59_by_1",
+ "typeString": "int_const 59"
+ },
+ "value": "59"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5807:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830393133313237313932326561613630366666666666666666666666666666666666",
+ "id": 3791,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5826:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3087892399045852422628542596524428754943_by_1",
+ "typeString": "int_const 3087...(32 digits omitted)...4943"
+ },
+ "value": "0x09131271922eaa606fffffffffffffffff"
+ },
+ "src": "5807:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3793,
+ "nodeType": "ExpressionStatement",
+ "src": "5807:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3798,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3794,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5873:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3796,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3630",
+ "id": 3795,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5886:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_60_by_1",
+ "typeString": "int_const 60"
+ },
+ "value": "60"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5873:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830386233383066333535383636386334366666666666666666666666666666666666",
+ "id": 3797,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5892:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2960860296012425255212778080756987592703_by_1",
+ "typeString": "int_const 2960...(32 digits omitted)...2703"
+ },
+ "value": "0x08b380f3558668c46fffffffffffffffff"
+ },
+ "src": "5873:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3799,
+ "nodeType": "ExpressionStatement",
+ "src": "5873:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3804,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3800,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5939:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3802,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3631",
+ "id": 3801,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5952:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_61_by_1",
+ "typeString": "int_const 61"
+ },
+ "value": "61"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5939:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830383537646466303131376566613231356266666666666666666666666666666666",
+ "id": 3803,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5958:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2839054137771012724926516325250418868223_by_1",
+ "typeString": "int_const 2839...(32 digits omitted)...8223"
+ },
+ "value": "0x0857ddf0117efa215bffffffffffffffff"
+ },
+ "src": "5939:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3805,
+ "nodeType": "ExpressionStatement",
+ "src": "5939:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3810,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3806,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6005:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3808,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3632",
+ "id": 3807,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6018:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_62_by_1",
+ "typeString": "int_const 62"
+ },
+ "value": "62"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6005:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830376666666666666666666666666666666666666666666666666666666666666666",
+ "id": 3809,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6024:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2722258935367507707706996859454145691647_by_1",
+ "typeString": "int_const 2722...(32 digits omitted)...1647"
+ },
+ "value": "0x07ffffffffffffffffffffffffffffffff"
+ },
+ "src": "6005:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3811,
+ "nodeType": "ExpressionStatement",
+ "src": "6005:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3816,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3812,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6071:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3814,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3633",
+ "id": 3813,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6084:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_63_by_1",
+ "typeString": "int_const 63"
+ },
+ "value": "63"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6071:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830376162626636663661626239643038376666666666666666666666666666666666",
+ "id": 3815,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6090:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2610268544229484780765045556213696167935_by_1",
+ "typeString": "int_const 2610...(32 digits omitted)...7935"
+ },
+ "value": "0x07abbf6f6abb9d087fffffffffffffffff"
+ },
+ "src": "6071:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3817,
+ "nodeType": "ExpressionStatement",
+ "src": "6071:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3822,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3818,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6137:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3820,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3634",
+ "id": 3819,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6150:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_64_by_1",
+ "typeString": "int_const 64"
+ },
+ "value": "64"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6137:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830373561663632636261633935663764666137666666666666666666666666666666",
+ "id": 3821,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6156:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2502885300319193958571922333378000453631_by_1",
+ "typeString": "int_const 2502...(32 digits omitted)...3631"
+ },
+ "value": "0x075af62cbac95f7dfa7fffffffffffffff"
+ },
+ "src": "6137:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3823,
+ "nodeType": "ExpressionStatement",
+ "src": "6137:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3828,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3824,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6203:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3826,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3635",
+ "id": 3825,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6216:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_65_by_1",
+ "typeString": "int_const 65"
+ },
+ "value": "65"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6203:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830373064376662373435326531383761633133666666666666666666666666666666",
+ "id": 3827,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6222:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2399919671254773659805118819743970623487_by_1",
+ "typeString": "int_const 2399...(32 digits omitted)...3487"
+ },
+ "value": "0x070d7fb7452e187ac13fffffffffffffff"
+ },
+ "src": "6203:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3829,
+ "nodeType": "ExpressionStatement",
+ "src": "6203:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3834,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3830,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6269:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3832,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3636",
+ "id": 3831,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6282:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_66_by_1",
+ "typeString": "int_const 66"
+ },
+ "value": "66"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6269:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830366333333930656363386166333739323935666666666666666666666666666666",
+ "id": 3833,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6288:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2301189921783908737703717501630802821119_by_1",
+ "typeString": "int_const 2301...(32 digits omitted)...1119"
+ },
+ "value": "0x06c3390ecc8af379295fffffffffffffff"
+ },
+ "src": "6269:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3835,
+ "nodeType": "ExpressionStatement",
+ "src": "6269:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3840,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3836,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6335:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3838,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3637",
+ "id": 3837,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6348:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_67_by_1",
+ "typeString": "int_const 67"
+ },
+ "value": "67"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6335:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830363763303061336230376666633031666436666666666666666666666666666666",
+ "id": 3839,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6354:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2206521793019491601704439134261549727743_by_1",
+ "typeString": "int_const 2206...(32 digits omitted)...7743"
+ },
+ "value": "0x067c00a3b07ffc01fd6fffffffffffffff"
+ },
+ "src": "6335:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3841,
+ "nodeType": "ExpressionStatement",
+ "src": "6335:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3846,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3842,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6401:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3844,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3638",
+ "id": 3843,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6414:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_68_by_1",
+ "typeString": "int_const 68"
+ },
+ "value": "68"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6401:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830363337623634376333396362623964336432376666666666666666666666666666",
+ "id": 3845,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6420:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2115748194871134515168564783402692116479_by_1",
+ "typeString": "int_const 2115...(32 digits omitted)...6479"
+ },
+ "value": "0x0637b647c39cbb9d3d27ffffffffffffff"
+ },
+ "src": "6401:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3847,
+ "nodeType": "ExpressionStatement",
+ "src": "6401:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3852,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3848,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6467:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3850,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3639",
+ "id": 3849,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6480:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_69_by_1",
+ "typeString": "int_const 69"
+ },
+ "value": "69"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6467:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830356636336231666331303464626433393538376666666666666666666666666666",
+ "id": 3851,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6486:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2028708911129671949307566740521183346687_by_1",
+ "typeString": "int_const 2028...(32 digits omitted)...6687"
+ },
+ "value": "0x05f63b1fc104dbd39587ffffffffffffff"
+ },
+ "src": "6467:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3853,
+ "nodeType": "ExpressionStatement",
+ "src": "6467:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3858,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3854,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6533:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3856,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3730",
+ "id": 3855,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6546:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_70_by_1",
+ "typeString": "int_const 70"
+ },
+ "value": "70"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6533:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830356237373139353562333665313266373233356666666666666666666666666666",
+ "id": 3857,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6552:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1945250316684124513375052119057996185599_by_1",
+ "typeString": "int_const 1945...(32 digits omitted)...5599"
+ },
+ "value": "0x05b771955b36e12f7235ffffffffffffff"
+ },
+ "src": "6533:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3859,
+ "nodeType": "ExpressionStatement",
+ "src": "6533:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3864,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3860,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6599:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3862,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3731",
+ "id": 3861,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6612:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_71_by_1",
+ "typeString": "int_const 71"
+ },
+ "value": "71"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6599:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830353762336434396464613834353536643666366666666666666666666666666666",
+ "id": 3863,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6618:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1865225106372009884014199587421481336831_by_1",
+ "typeString": "int_const 1865...(32 digits omitted)...6831"
+ },
+ "value": "0x057b3d49dda84556d6f6ffffffffffffff"
+ },
+ "src": "6599:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3865,
+ "nodeType": "ExpressionStatement",
+ "src": "6599:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3870,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3866,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6665:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3868,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3732",
+ "id": 3867,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6678:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_72_by_1",
+ "typeString": "int_const 72"
+ },
+ "value": "72"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6665:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830353431383330393562326338656365636633306666666666666666666666666666",
+ "id": 3869,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6684:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1788492034984419117666073304513300660223_by_1",
+ "typeString": "int_const 1788...(32 digits omitted)...0223"
+ },
+ "value": "0x054183095b2c8ececf30ffffffffffffff"
+ },
+ "src": "6665:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3871,
+ "nodeType": "ExpressionStatement",
+ "src": "6665:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3876,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3872,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6731:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3874,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3733",
+ "id": 3873,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6744:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_73_by_1",
+ "typeString": "int_const 73"
+ },
+ "value": "73"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6731:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830353061323862653633356361326238383866373766666666666666666666666666",
+ "id": 3875,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6750:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1714915667966964990208967912165996494847_by_1",
+ "typeString": "int_const 1714...(32 digits omitted)...4847"
+ },
+ "value": "0x050a28be635ca2b888f77fffffffffffff"
+ },
+ "src": "6731:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3877,
+ "nodeType": "ExpressionStatement",
+ "src": "6731:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3882,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3878,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6797:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3880,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3734",
+ "id": 3879,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6810:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_74_by_1",
+ "typeString": "int_const 74"
+ },
+ "value": "74"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6797:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830346435313536363339373038633964623333633366666666666666666666666666",
+ "id": 3881,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6816:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1644366142376587317378242124992063995903_by_1",
+ "typeString": "int_const 1644...(32 digits omitted)...5903"
+ },
+ "value": "0x04d5156639708c9db33c3fffffffffffff"
+ },
+ "src": "6797:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3883,
+ "nodeType": "ExpressionStatement",
+ "src": "6797:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3888,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3884,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6863:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3886,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3735",
+ "id": 3885,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6876:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_75_by_1",
+ "typeString": "int_const 75"
+ },
+ "value": "75"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6863:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830346132333130353837333837356264353264666466666666666666666666666666",
+ "id": 3887,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6882:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1576718937672301888428671268411708276735_by_1",
+ "typeString": "int_const 1576...(32 digits omitted)...6735"
+ },
+ "value": "0x04a23105873875bd52dfdfffffffffffff"
+ },
+ "src": "6863:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3889,
+ "nodeType": "ExpressionStatement",
+ "src": "6863:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3894,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3890,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6929:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3892,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3736",
+ "id": 3891,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6942:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_76_by_1",
+ "typeString": "int_const 76"
+ },
+ "value": "76"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6929:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830343731363439643837313939616139393037353666666666666666666666666666",
+ "id": 3893,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6948:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1511854655935336643558907106913628979199_by_1",
+ "typeString": "int_const 1511...(32 digits omitted)...9199"
+ },
+ "value": "0x0471649d87199aa990756fffffffffffff"
+ },
+ "src": "6929:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3895,
+ "nodeType": "ExpressionStatement",
+ "src": "6929:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3900,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3896,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6995:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3898,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3737",
+ "id": 3897,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7008:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_77_by_1",
+ "typeString": "int_const 77"
+ },
+ "value": "77"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6995:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830343432396132316130323964346331343537636662666666666666666666666666",
+ "id": 3899,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7014:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1449658811130741678082357454851673161727_by_1",
+ "typeString": "int_const 1449...(32 digits omitted)...1727"
+ },
+ "value": "0x04429a21a029d4c1457cfbffffffffffff"
+ },
+ "src": "6995:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3901,
+ "nodeType": "ExpressionStatement",
+ "src": "6995:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3906,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3902,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7061:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3904,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3738",
+ "id": 3903,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7074:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_78_by_1",
+ "typeString": "int_const 78"
+ },
+ "value": "78"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7061:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830343135626336643666623764643731616632636233666666666666666666666666",
+ "id": 3905,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7080:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1390021627038517938156314751863424548863_by_1",
+ "typeString": "int_const 1390...(32 digits omitted)...8863"
+ },
+ "value": "0x0415bc6d6fb7dd71af2cb3ffffffffffff"
+ },
+ "src": "7061:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3907,
+ "nodeType": "ExpressionStatement",
+ "src": "7061:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3912,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3908,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7127:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3910,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3739",
+ "id": 3909,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7140:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_79_by_1",
+ "typeString": "int_const 79"
+ },
+ "value": "79"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7127:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830336561623733623362626665323832323433636531666666666666666666666666",
+ "id": 3911,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7146:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1332837843497611250583009129150422188031_by_1",
+ "typeString": "int_const 1332...(32 digits omitted)...8031"
+ },
+ "value": "0x03eab73b3bbfe282243ce1ffffffffffff"
+ },
+ "src": "7127:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3913,
+ "nodeType": "ExpressionStatement",
+ "src": "7127:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3918,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3914,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7193:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3916,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3830",
+ "id": 3915,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7206:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_80_by_1",
+ "typeString": "int_const 80"
+ },
+ "value": "80"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7193:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830336331373731616339666236623463313865323239666666666666666666666666",
+ "id": 3917,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7212:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1278006530620790610545644364558728429567_by_1",
+ "typeString": "int_const 1278...(32 digits omitted)...9567"
+ },
+ "value": "0x03c1771ac9fb6b4c18e229ffffffffffff"
+ },
+ "src": "7193:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3919,
+ "nodeType": "ExpressionStatement",
+ "src": "7193:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3924,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3920,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7259:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3922,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3831",
+ "id": 3921,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7272:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_81_by_1",
+ "typeString": "int_const 81"
+ },
+ "value": "81"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7259:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830333939653936383937363930343138663738353235376666666666666666666666",
+ "id": 3923,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7278:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1225430910652498332846748256431392161791_by_1",
+ "typeString": "int_const 1225...(32 digits omitted)...1791"
+ },
+ "value": "0x0399e96897690418f785257fffffffffff"
+ },
+ "src": "7259:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3925,
+ "nodeType": "ExpressionStatement",
+ "src": "7259:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3930,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3926,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7325:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3928,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3832",
+ "id": 3927,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7338:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_82_by_1",
+ "typeString": "int_const 82"
+ },
+ "value": "82"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7325:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830333733666334353663353362623737396266306561396666666666666666666666",
+ "id": 3929,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7344:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1175018187155249585623915264673694351359_by_1",
+ "typeString": "int_const 1175...(32 digits omitted)...1359"
+ },
+ "value": "0x0373fc456c53bb779bf0ea9fffffffffff"
+ },
+ "src": "7325:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3931,
+ "nodeType": "ExpressionStatement",
+ "src": "7325:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3936,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3932,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7391:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3934,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3833",
+ "id": 3933,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7404:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_83_by_1",
+ "typeString": "int_const 83"
+ },
+ "value": "83"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7391:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830333466396538653439306334386536376536616238626666666666666666666666",
+ "id": 3935,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7410:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1126679381223093780446468558216906145791_by_1",
+ "typeString": "int_const 1126...(32 digits omitted)...5791"
+ },
+ "value": "0x034f9e8e490c48e67e6ab8bfffffffffff"
+ },
+ "src": "7391:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3937,
+ "nodeType": "ExpressionStatement",
+ "src": "7391:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3942,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3938,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7457:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3940,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3834",
+ "id": 3939,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7470:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_84_by_1",
+ "typeString": "int_const 84"
+ },
+ "value": "84"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7457:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830333263626664346137616463373930353630623333333766666666666666666666",
+ "id": 3941,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7476:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1080329174433053119456411494679599644671_by_1",
+ "typeString": "int_const 1080...(32 digits omitted)...4671"
+ },
+ "value": "0x032cbfd4a7adc790560b3337ffffffffff"
+ },
+ "src": "7457:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3943,
+ "nodeType": "ExpressionStatement",
+ "src": "7457:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3948,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3944,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7523:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3946,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3835",
+ "id": 3945,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7536:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_85_by_1",
+ "typeString": "int_const 85"
+ },
+ "value": "85"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7523:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830333062353035373066366535643261636361393436313366666666666666666666",
+ "id": 3947,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7542:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1035885758257346189907937735244580388863_by_1",
+ "typeString": "int_const 1035...(32 digits omitted)...8863"
+ },
+ "value": "0x030b50570f6e5d2acca94613ffffffffff"
+ },
+ "src": "7523:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3949,
+ "nodeType": "ExpressionStatement",
+ "src": "7523:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3954,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3950,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7589:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3952,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3836",
+ "id": 3951,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7602:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_86_by_1",
+ "typeString": "int_const 86"
+ },
+ "value": "86"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7589:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830326562343066396636323066646136623536633238363166666666666666666666",
+ "id": 3953,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7608:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_993270689670607839608468400662101622783_by_1",
+ "typeString": "int_const 9932...(31 digits omitted)...2783"
+ },
+ "value": "0x02eb40f9f620fda6b56c2861ffffffffff"
+ },
+ "src": "7589:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3955,
+ "nodeType": "ExpressionStatement",
+ "src": "7589:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3960,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3956,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7655:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3958,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3837",
+ "id": 3957,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7668:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_87_by_1",
+ "typeString": "int_const 87"
+ },
+ "value": "87"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7655:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830326363383334306563623064306635323061366166353866666666666666666666",
+ "id": 3959,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7674:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_952408752697250790372885759853747765247_by_1",
+ "typeString": "int_const 9524...(31 digits omitted)...5247"
+ },
+ "value": "0x02cc8340ecb0d0f520a6af58ffffffffff"
+ },
+ "src": "7655:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3961,
+ "nodeType": "ExpressionStatement",
+ "src": "7655:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3966,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3962,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7721:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3964,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3838",
+ "id": 3963,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7734:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_88_by_1",
+ "typeString": "int_const 88"
+ },
+ "value": "88"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7721:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830326166303934383133383061306133356366316261303266666666666666666666",
+ "id": 3965,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7740:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_913227825654598849673391073164504596479_by_1",
+ "typeString": "int_const 9132...(31 digits omitted)...6479"
+ },
+ "value": "0x02af09481380a0a35cf1ba02ffffffffff"
+ },
+ "src": "7721:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3967,
+ "nodeType": "ExpressionStatement",
+ "src": "7721:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3972,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3968,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7787:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3970,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3839",
+ "id": 3969,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7800:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_89_by_1",
+ "typeString": "int_const 89"
+ },
+ "value": "89"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7787:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830323932633562646433623932656338313032383762316233666666666666666666",
+ "id": 3971,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7806:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_875658753857474668265023456619450597375_by_1",
+ "typeString": "int_const 8756...(31 digits omitted)...7375"
+ },
+ "value": "0x0292c5bdd3b92ec810287b1b3fffffffff"
+ },
+ "src": "7787:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3973,
+ "nodeType": "ExpressionStatement",
+ "src": "7787:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3978,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3974,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7853:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3976,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3930",
+ "id": 3975,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7866:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_90_by_1",
+ "typeString": "int_const 90"
+ },
+ "value": "90"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7853:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830323737616264636461623037643561373761633664366239666666666666666666",
+ "id": 3977,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7872:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_839635227559564507480479102760887779327_by_1",
+ "typeString": "int_const 8396...(31 digits omitted)...9327"
+ },
+ "value": "0x0277abdcdab07d5a77ac6d6b9fffffffff"
+ },
+ "src": "7853:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3979,
+ "nodeType": "ExpressionStatement",
+ "src": "7853:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3984,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3980,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7919:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3982,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3931",
+ "id": 3981,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7932:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_91_by_1",
+ "typeString": "int_const 91"
+ },
+ "value": "91"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7919:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830323564616636363534623165616135356664363464663565666666666666666666",
+ "id": 3983,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7938:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_805093664916125437948904238798044397567_by_1",
+ "typeString": "int_const 8050...(31 digits omitted)...7567"
+ },
+ "value": "0x025daf6654b1eaa55fd64df5efffffffff"
+ },
+ "src": "7919:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3985,
+ "nodeType": "ExpressionStatement",
+ "src": "7919:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3990,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3986,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7985:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3988,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3932",
+ "id": 3987,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7998:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_92_by_1",
+ "typeString": "int_const 92"
+ },
+ "value": "92"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7985:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830323434633439633634386261613938313932646365383862376666666666666666",
+ "id": 3989,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8004:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_771973099761463105605096142810743046143_by_1",
+ "typeString": "int_const 7719...(31 digits omitted)...6143"
+ },
+ "value": "0x0244c49c648baa98192dce88b7ffffffff"
+ },
+ "src": "7985:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3991,
+ "nodeType": "ExpressionStatement",
+ "src": "7985:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3996,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3992,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8051:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3994,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3933",
+ "id": 3993,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8064:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_93_by_1",
+ "typeString": "int_const 93"
+ },
+ "value": "93"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8051:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830323263653033636435363139613331316232343731323638626666666666666666",
+ "id": 3995,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8070:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_740215074003106313787373698556008333311_by_1",
+ "typeString": "int_const 7402...(31 digits omitted)...3311"
+ },
+ "value": "0x022ce03cd5619a311b2471268bffffffff"
+ },
+ "src": "8051:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3997,
+ "nodeType": "ExpressionStatement",
+ "src": "8051:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4002,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3998,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8117:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4000,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3934",
+ "id": 3999,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8130:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_94_by_1",
+ "typeString": "int_const 94"
+ },
+ "value": "94"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8117:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830323135663737633034356662653838353635346134346130666666666666666666",
+ "id": 4001,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8136:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_709763534442753181219281418466841591807_by_1",
+ "typeString": "int_const 7097...(31 digits omitted)...1807"
+ },
+ "value": "0x0215f77c045fbe885654a44a0fffffffff"
+ },
+ "src": "8117:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4003,
+ "nodeType": "ExpressionStatement",
+ "src": "8117:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4008,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4004,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8183:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4006,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3935",
+ "id": 4005,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8196:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_95_by_1",
+ "typeString": "int_const 95"
+ },
+ "value": "95"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8183:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830316666666666666666666666666666666666666666666666666666666666666666",
+ "id": 4007,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8202:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_680564733841876926926749214863536422911_by_1",
+ "typeString": "int_const 6805...(31 digits omitted)...2911"
+ },
+ "value": "0x01ffffffffffffffffffffffffffffffff"
+ },
+ "src": "8183:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4009,
+ "nodeType": "ExpressionStatement",
+ "src": "8183:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4014,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4010,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8249:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4012,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3936",
+ "id": 4011,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8262:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_96_by_1",
+ "typeString": "int_const 96"
+ },
+ "value": "96"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8249:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830316561656664626461616565373432316663346433656465356666666666666666",
+ "id": 4013,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8268:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_652567136057371195186997586203332575231_by_1",
+ "typeString": "int_const 6525...(31 digits omitted)...5231"
+ },
+ "value": "0x01eaefdbdaaee7421fc4d3ede5ffffffff"
+ },
+ "src": "8249:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4015,
+ "nodeType": "ExpressionStatement",
+ "src": "8249:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4020,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4016,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8315:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4018,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3937",
+ "id": 4017,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8328:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_97_by_1",
+ "typeString": "int_const 97"
+ },
+ "value": "97"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8315:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830316436626438623265623235376466376538636135376230396266666666666666",
+ "id": 4019,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8334:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_625721325079798489641586010116704960511_by_1",
+ "typeString": "int_const 6257...(31 digits omitted)...0511"
+ },
+ "value": "0x01d6bd8b2eb257df7e8ca57b09bfffffff"
+ },
+ "src": "8315:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4021,
+ "nodeType": "ExpressionStatement",
+ "src": "8315:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4026,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4022,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8381:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4024,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3938",
+ "id": 4023,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8394:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_98_by_1",
+ "typeString": "int_const 98"
+ },
+ "value": "98"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8381:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830316333356665646431346238363165623034343366376631333366666666666666",
+ "id": 4025,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8400:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_599979917813693414950432886451725139967_by_1",
+ "typeString": "int_const 5999...(31 digits omitted)...9967"
+ },
+ "value": "0x01c35fedd14b861eb0443f7f133fffffff"
+ },
+ "src": "8381:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4027,
+ "nodeType": "ExpressionStatement",
+ "src": "8381:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4032,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4028,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8447:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4030,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3939",
+ "id": 4029,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8460:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_99_by_1",
+ "typeString": "int_const 99"
+ },
+ "value": "99"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8447:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830316230636534336233323262636465346135366538616461356166666666666666",
+ "id": 4031,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8466:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_575297480445977184425850753341355720703_by_1",
+ "typeString": "int_const 5752...(31 digits omitted)...0703"
+ },
+ "value": "0x01b0ce43b322bcde4a56e8ada5afffffff"
+ },
+ "src": "8447:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4033,
+ "nodeType": "ExpressionStatement",
+ "src": "8447:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4038,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4034,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8513:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4036,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313030",
+ "id": 4035,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8525:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_100_by_1",
+ "typeString": "int_const 100"
+ },
+ "value": "100"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8513:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313966303032386563316666663030376635613139356133396466666666666666",
+ "id": 4037,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8532:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_551630448254872900425972804456347074559_by_1",
+ "typeString": "int_const 5516...(31 digits omitted)...4559"
+ },
+ "value": "0x019f0028ec1fff007f5a195a39dfffffff"
+ },
+ "src": "8513:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4039,
+ "nodeType": "ExpressionStatement",
+ "src": "8513:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4044,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4040,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8579:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4042,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313031",
+ "id": 4041,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8591:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_101_by_1",
+ "typeString": "int_const 101"
+ },
+ "value": "101"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8579:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313864656439316630653732656537346634396231356261353237666666666666",
+ "id": 4043,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8598:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_528937048717783628792119060092411707391_by_1",
+ "typeString": "int_const 5289...(31 digits omitted)...7391"
+ },
+ "value": "0x018ded91f0e72ee74f49b15ba527ffffff"
+ },
+ "src": "8579:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4045,
+ "nodeType": "ExpressionStatement",
+ "src": "8579:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4050,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4046,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8645:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4048,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313032",
+ "id": 4047,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8657:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_102_by_1",
+ "typeString": "int_const 102"
+ },
+ "value": "102"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8645:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313764386563376630343133366634653536313566643431613633666666666666",
+ "id": 4049,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8664:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_507177227782417987326846600868857380863_by_1",
+ "typeString": "int_const 5071...(31 digits omitted)...0863"
+ },
+ "value": "0x017d8ec7f04136f4e5615fd41a63ffffff"
+ },
+ "src": "8645:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4051,
+ "nodeType": "ExpressionStatement",
+ "src": "8645:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4056,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4052,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8711:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4054,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313033",
+ "id": 4053,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8723:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_103_by_1",
+ "typeString": "int_const 103"
+ },
+ "value": "103"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8711:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313664646336353536636462383462646338643132643232653666666666666666",
+ "id": 4055,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8730:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_486312579171031128343732298613950251007_by_1",
+ "typeString": "int_const 4863...(31 digits omitted)...1007"
+ },
+ "value": "0x016ddc6556cdb84bdc8d12d22e6fffffff"
+ },
+ "src": "8711:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4057,
+ "nodeType": "ExpressionStatement",
+ "src": "8711:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4062,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4058,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8777:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4060,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313034",
+ "id": 4059,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8789:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_104_by_1",
+ "typeString": "int_const 104"
+ },
+ "value": "104"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8777:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313565636635323737366131313535623562643833393538313466376666666666",
+ "id": 4061,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8796:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_466306276593002471003532891264408092671_by_1",
+ "typeString": "int_const 4663...(31 digits omitted)...2671"
+ },
+ "value": "0x015ecf52776a1155b5bd8395814f7fffff"
+ },
+ "src": "8777:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4063,
+ "nodeType": "ExpressionStatement",
+ "src": "8777:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4068,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4064,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8843:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4066,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313035",
+ "id": 4065,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8855:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_105_by_1",
+ "typeString": "int_const 105"
+ },
+ "value": "105"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8843:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313530363063323536636232336233623363633337353463663430666666666666",
+ "id": 4067,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8862:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_447123008746104779416515886102660251647_by_1",
+ "typeString": "int_const 4471...(31 digits omitted)...1647"
+ },
+ "value": "0x015060c256cb23b3b3cc3754cf40ffffff"
+ },
+ "src": "8843:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4069,
+ "nodeType": "ExpressionStatement",
+ "src": "8843:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4074,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4070,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8909:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4072,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313036",
+ "id": 4071,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8921:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_106_by_1",
+ "typeString": "int_const 106"
+ },
+ "value": "106"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8909:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313432386132663938643732386165323233646461623731356265336666666666",
+ "id": 4073,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8928:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_428728916991741247552240490495652921343_by_1",
+ "typeString": "int_const 4287...(31 digits omitted)...1343"
+ },
+ "value": "0x01428a2f98d728ae223ddab715be3fffff"
+ },
+ "src": "8909:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4075,
+ "nodeType": "ExpressionStatement",
+ "src": "8909:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4080,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4076,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8975:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4078,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313037",
+ "id": 4077,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8987:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_107_by_1",
+ "typeString": "int_const 107"
+ },
+ "value": "107"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8975:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313335343535393865356332333237366363663065646536383033346666666666",
+ "id": 4079,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8994:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_411091535594146829344560212836376117247_by_1",
+ "typeString": "int_const 4110...(31 digits omitted)...7247"
+ },
+ "value": "0x013545598e5c23276ccf0ede68034fffff"
+ },
+ "src": "8975:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4081,
+ "nodeType": "ExpressionStatement",
+ "src": "8975:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4086,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4082,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9041:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4084,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313038",
+ "id": 4083,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9053:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_108_by_1",
+ "typeString": "int_const 108"
+ },
+ "value": "108"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9041:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313238386334313631636531643666353462376636313038313139346666666666",
+ "id": 4085,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9060:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_394179734418075472107167272299635146751_by_1",
+ "typeString": "int_const 3941...(31 digits omitted)...6751"
+ },
+ "value": "0x01288c4161ce1d6f54b7f61081194fffff"
+ },
+ "src": "9041:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4087,
+ "nodeType": "ExpressionStatement",
+ "src": "9041:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4092,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4088,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9107:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4090,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313039",
+ "id": 4089,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9119:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_109_by_1",
+ "typeString": "int_const 109"
+ },
+ "value": "109"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9107:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313163353932373631633636366161363431643561303161343066313766666666",
+ "id": 4091,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9126:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_377963663983834160889726215582593318911_by_1",
+ "typeString": "int_const 3779...(31 digits omitted)...8911"
+ },
+ "value": "0x011c592761c666aa641d5a01a40f17ffff"
+ },
+ "src": "9107:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4093,
+ "nodeType": "ExpressionStatement",
+ "src": "9107:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4098,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4094,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9173:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4096,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313130",
+ "id": 4095,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9185:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_110_by_1",
+ "typeString": "int_const 110"
+ },
+ "value": "110"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9173:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313130613638383638306137353330353135663365366536636664636466666666",
+ "id": 4097,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9192:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_362414702782685419520589203652335239167_by_1",
+ "typeString": "int_const 3624...(31 digits omitted)...9167"
+ },
+ "value": "0x0110a688680a7530515f3e6e6cfdcdffff"
+ },
+ "src": "9173:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4099,
+ "nodeType": "ExpressionStatement",
+ "src": "9173:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4104,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4100,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9239:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4102,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313131",
+ "id": 4101,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9251:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_111_by_1",
+ "typeString": "int_const 111"
+ },
+ "value": "111"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9239:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313035366631623562656466373563366263623263653861656434323866666666",
+ "id": 4103,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9258:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_347505406759629484539078662328460836863_by_1",
+ "typeString": "int_const 3475...(31 digits omitted)...6863"
+ },
+ "value": "0x01056f1b5bedf75c6bcb2ce8aed428ffff"
+ },
+ "src": "9239:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4105,
+ "nodeType": "ExpressionStatement",
+ "src": "9239:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4110,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4106,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9305:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4108,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313132",
+ "id": 4107,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9317:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_112_by_1",
+ "typeString": "int_const 112"
+ },
+ "value": "112"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9305:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306661616463656365656666386130383930663338373566303038323737666666",
+ "id": 4109,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9324:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_333209460874402812645752271223906598911_by_1",
+ "typeString": "int_const 3332...(31 digits omitted)...8911"
+ },
+ "value": "0x00faadceceeff8a0890f3875f008277fff"
+ },
+ "src": "9305:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4111,
+ "nodeType": "ExpressionStatement",
+ "src": "9305:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4116,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4112,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9371:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4114,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313133",
+ "id": 4113,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9383:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_113_by_1",
+ "typeString": "int_const 113"
+ },
+ "value": "113"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9371:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306630356463366232376564616433303633383861363030663662613062666666",
+ "id": 4115,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9390:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_319501632655197652636411056021540225023_by_1",
+ "typeString": "int_const 3195...(31 digits omitted)...5023"
+ },
+ "value": "0x00f05dc6b27edad306388a600f6ba0bfff"
+ },
+ "src": "9371:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4117,
+ "nodeType": "ExpressionStatement",
+ "src": "9371:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4122,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4118,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9437:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4120,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313134",
+ "id": 4119,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9449:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_114_by_1",
+ "typeString": "int_const 114"
+ },
+ "value": "114"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9437:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306536376135613235646134313036336465313439356435623138636462666666",
+ "id": 4121,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9456:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_306357727663124583211687061200571318271_by_1",
+ "typeString": "int_const 3063...(31 digits omitted)...8271"
+ },
+ "value": "0x00e67a5a25da41063de1495d5b18cdbfff"
+ },
+ "src": "9437:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4123,
+ "nodeType": "ExpressionStatement",
+ "src": "9437:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4128,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4124,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9503:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4126,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313135",
+ "id": 4125,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9515:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_115_by_1",
+ "typeString": "int_const 115"
+ },
+ "value": "115"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9503:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306463666631313562313465656464653666633361613533353366326534666666",
+ "id": 4127,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9522:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_293754546788812396405978813098581970943_by_1",
+ "typeString": "int_const 2937...(31 digits omitted)...0943"
+ },
+ "value": "0x00dcff115b14eedde6fc3aa5353f2e4fff"
+ },
+ "src": "9503:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4129,
+ "nodeType": "ExpressionStatement",
+ "src": "9503:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4134,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4130,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9569:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4132,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313136",
+ "id": 4131,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9581:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_116_by_1",
+ "typeString": "int_const 116"
+ },
+ "value": "116"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9569:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306433653761333932343331323339396639616165326530663836386638666666",
+ "id": 4133,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9588:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_281669845305773445111617137421885345791_by_1",
+ "typeString": "int_const 2816...(31 digits omitted)...5791"
+ },
+ "value": "0x00d3e7a3924312399f9aae2e0f868f8fff"
+ },
+ "src": "9569:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4135,
+ "nodeType": "ExpressionStatement",
+ "src": "9569:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4140,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4136,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9635:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4138,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313137",
+ "id": 4137,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9647:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_117_by_1",
+ "typeString": "int_const 117"
+ },
+ "value": "117"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9635:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306362326666353239656237316534313538326363636435613165653236666666",
+ "id": 4139,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9654:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_270082293608263279864102872957453496319_by_1",
+ "typeString": "int_const 2700...(31 digits omitted)...6319"
+ },
+ "value": "0x00cb2ff529eb71e41582cccd5a1ee26fff"
+ },
+ "src": "9635:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4141,
+ "nodeType": "ExpressionStatement",
+ "src": "9635:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4146,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4142,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9701:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4144,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313138",
+ "id": 4143,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9713:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_118_by_1",
+ "typeString": "int_const 118"
+ },
+ "value": "118"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9701:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306332643431356333646239373461623332613531383430633062363765646666",
+ "id": 4145,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9720:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_258971439564336547476984432763364437503_by_1",
+ "typeString": "int_const 2589...(31 digits omitted)...7503"
+ },
+ "value": "0x00c2d415c3db974ab32a51840c0b67edff"
+ },
+ "src": "9701:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4147,
+ "nodeType": "ExpressionStatement",
+ "src": "9701:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4152,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4148,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9767:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4150,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313139",
+ "id": 4149,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9779:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_119_by_1",
+ "typeString": "int_const 119"
+ },
+ "value": "119"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9767:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306261643033653764383833663639616435623061313836313834653036626666",
+ "id": 4151,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9786:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_248317672417651959902117100034610719743_by_1",
+ "typeString": "int_const 2483...(31 digits omitted)...9743"
+ },
+ "value": "0x00bad03e7d883f69ad5b0a186184e06bff"
+ },
+ "src": "9767:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4153,
+ "nodeType": "ExpressionStatement",
+ "src": "9767:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4158,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4154,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9833:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4156,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313230",
+ "id": 4155,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9845:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_120_by_1",
+ "typeString": "int_const 120"
+ },
+ "value": "120"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9833:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306233323064303362326333343364343832396162643630373566306363356666",
+ "id": 4157,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9852:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_238102188174312697593221439720218478079_by_1",
+ "typeString": "int_const 2381...(31 digits omitted)...8079"
+ },
+ "value": "0x00b320d03b2c343d4829abd6075f0cc5ff"
+ },
+ "src": "9833:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4159,
+ "nodeType": "ExpressionStatement",
+ "src": "9833:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4164,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4160,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9899:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4162,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313231",
+ "id": 4161,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9911:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_121_by_1",
+ "typeString": "int_const 121"
+ },
+ "value": "121"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9899:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306162633235323034653032383238643733633665383062636462316139356266",
+ "id": 4163,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9918:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_228306956413649712418347768277622232511_by_1",
+ "typeString": "int_const 2283...(31 digits omitted)...2511"
+ },
+ "value": "0x00abc25204e02828d73c6e80bcdb1a95bf"
+ },
+ "src": "9899:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4165,
+ "nodeType": "ExpressionStatement",
+ "src": "9899:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4170,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4166,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9965:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4168,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313232",
+ "id": 4167,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9977:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_122_by_1",
+ "typeString": "int_const 122"
+ },
+ "value": "122"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9965:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306134623136663734656534626232303430613165633663313566626266326466",
+ "id": 4169,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9984:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_218914688464368667066255864092044292831_by_1",
+ "typeString": "int_const 2189...(31 digits omitted)...2831"
+ },
+ "value": "0x00a4b16f74ee4bb2040a1ec6c15fbbf2df"
+ },
+ "src": "9965:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4171,
+ "nodeType": "ExpressionStatement",
+ "src": "9965:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4176,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4172,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "10031:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4174,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313233",
+ "id": 4173,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10043:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_123_by_1",
+ "typeString": "int_const 123"
+ },
+ "value": "123"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10031:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830303964656166373336616331663536396465623162356165336633366331333066",
+ "id": 4175,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10050:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_209908806889891126870119775672831054607_by_1",
+ "typeString": "int_const 2099...(31 digits omitted)...4607"
+ },
+ "value": "0x009deaf736ac1f569deb1b5ae3f36c130f"
+ },
+ "src": "10031:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4177,
+ "nodeType": "ExpressionStatement",
+ "src": "10031:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4182,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4178,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "10097:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4180,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313234",
+ "id": 4179,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10109:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_124_by_1",
+ "typeString": "int_const 124"
+ },
+ "value": "124"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10097:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830303937366264393935326337616139353766353933376437393065663635303337",
+ "id": 4181,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10116:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_201273416229031359487226059686877220919_by_1",
+ "typeString": "int_const 2012...(31 digits omitted)...0919"
+ },
+ "value": "0x00976bd9952c7aa957f5937d790ef65037"
+ },
+ "src": "10097:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4183,
+ "nodeType": "ExpressionStatement",
+ "src": "10097:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4188,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4184,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "10163:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4186,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313235",
+ "id": 4185,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10175:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_125_by_1",
+ "typeString": "int_const 125"
+ },
+ "value": "125"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10163:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830303931333132373139323265616136303634623733613232643062643466326266",
+ "id": 4187,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10182:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_192993274940365776401274035698589299391_by_1",
+ "typeString": "int_const 1929...(31 digits omitted)...9391"
+ },
+ "value": "0x009131271922eaa6064b73a22d0bd4f2bf"
+ },
+ "src": "10163:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4189,
+ "nodeType": "ExpressionStatement",
+ "src": "10163:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4194,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4190,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "10229:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4192,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313236",
+ "id": 4191,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10241:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_126_by_1",
+ "typeString": "int_const 126"
+ },
+ "value": "126"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10229:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830303862333830663335353836363863343663393163343961326638653936376239",
+ "id": 4193,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10248:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_185053768500776578446843424638883162041_by_1",
+ "typeString": "int_const 1850...(31 digits omitted)...2041"
+ },
+ "value": "0x008b380f3558668c46c91c49a2f8e967b9"
+ },
+ "src": "10229:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4195,
+ "nodeType": "ExpressionStatement",
+ "src": "10229:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4200,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4196,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "10295:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4198,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313237",
+ "id": 4197,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10307:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_127_by_1",
+ "typeString": "int_const 127"
+ },
+ "value": "127"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10295:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830303835376464663031313765666132313539353239313238333966363437336536",
+ "id": 4199,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10314:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_177440883610688295304820354615089591270_by_1",
+ "typeString": "int_const 1774...(31 digits omitted)...1270"
+ },
+ "value": "0x00857ddf0117efa215952912839f6473e6"
+ },
+ "src": "10295:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4201,
+ "nodeType": "ExpressionStatement",
+ "src": "10295:55:7"
+ }
+ ]
+ },
+ "documentation": null,
+ "id": 4203,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "initMaxExpArray",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 3624,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "1891:2:7"
+ },
+ "returnParameters": {
+ "id": 3625,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "1902:0:7"
+ },
+ "scope": 8977,
+ "src": "1867:8491:7",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "constant": false,
+ "id": 4207,
+ "mutability": "mutable",
+ "name": "lambertArray",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "10416:33:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 4204,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "10416:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4206,
+ "length": {
+ "argumentTypes": null,
+ "hexValue": "313238",
+ "id": 4205,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10424:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_128_by_1",
+ "typeString": "int_const 128"
+ },
+ "value": "128"
+ },
+ "nodeType": "ArrayTypeName",
+ "src": "10416:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage_ptr",
+ "typeString": "uint256[128]"
+ }
+ },
+ "value": null,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 4978,
+ "nodeType": "Block",
+ "src": "10492:8328:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4214,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4210,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "10503:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4212,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 4211,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10518:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10503:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783630653339336336386432306231626430396465616162633033373362396335",
+ "id": 4213,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10523:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_128787536227304155647383678419039664581_by_1",
+ "typeString": "int_const 1287...(31 digits omitted)...4581"
+ },
+ "value": "0x60e393c68d20b1bd09deaabc0373b9c5"
+ },
+ "src": "10503:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4215,
+ "nodeType": "ExpressionStatement",
+ "src": "10503:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4220,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4216,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "10568:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4218,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 4217,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10583:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10568:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783566386634366534383534313230393839656439343731396662346332303131",
+ "id": 4219,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10588:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_127020595924271037561532833511427022865_by_1",
+ "typeString": "int_const 1270...(31 digits omitted)...2865"
+ },
+ "value": "0x5f8f46e4854120989ed94719fb4c2011"
+ },
+ "src": "10568:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4221,
+ "nodeType": "ExpressionStatement",
+ "src": "10568:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4226,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4222,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "10633:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4224,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 4223,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10648:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10633:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783565343739656262393132396662316237653732613634386639393262363036",
+ "id": 4225,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10653:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_125319304162047910149801695424990590470_by_1",
+ "typeString": "int_const 1253...(31 digits omitted)...0470"
+ },
+ "value": "0x5e479ebb9129fb1b7e72a648f992b606"
+ },
+ "src": "10633:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4227,
+ "nodeType": "ExpressionStatement",
+ "src": "10633:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4232,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4228,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "10698:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4230,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "33",
+ "id": 4229,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10713:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3_by_1",
+ "typeString": "int_const 3"
+ },
+ "value": "3"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10698:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783564306264323366653432646665646465326539353836626531326238356665",
+ "id": 4231,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10718:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_123679583241450252008727309686047213054_by_1",
+ "typeString": "int_const 1236...(31 digits omitted)...3054"
+ },
+ "value": "0x5d0bd23fe42dfedde2e9586be12b85fe"
+ },
+ "src": "10698:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4233,
+ "nodeType": "ExpressionStatement",
+ "src": "10698:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4238,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4234,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "10763:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4236,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "34",
+ "id": 4235,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10778:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4_by_1",
+ "typeString": "int_const 4"
+ },
+ "value": "4"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10763:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783562646232396464656539373933303864646663613831616565623830393561",
+ "id": 4237,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10783:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_122097709790504811543485325791668472154_by_1",
+ "typeString": "int_const 1220...(31 digits omitted)...2154"
+ },
+ "value": "0x5bdb29ddee979308ddfca81aeeb8095a"
+ },
+ "src": "10763:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4239,
+ "nodeType": "ExpressionStatement",
+ "src": "10763:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4244,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4240,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "10828:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4242,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "35",
+ "id": 4241,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10843:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_5_by_1",
+ "typeString": "int_const 5"
+ },
+ "value": "5"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10828:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783561623466643861323630643263376532633064326166636630303039646164",
+ "id": 4243,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10848:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_120570275450071204896029314248949669293_by_1",
+ "typeString": "int_const 1205...(31 digits omitted)...9293"
+ },
+ "value": "0x5ab4fd8a260d2c7e2c0d2afcf0009dad"
+ },
+ "src": "10828:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4245,
+ "nodeType": "ExpressionStatement",
+ "src": "10828:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4250,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4246,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "10893:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4248,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "36",
+ "id": 4247,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10908:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6_by_1",
+ "typeString": "int_const 6"
+ },
+ "value": "6"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10893:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783539393862333133353961353564343837323463363563663039303031323231",
+ "id": 4249,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10913:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_119094152831753027058824439515169428001_by_1",
+ "typeString": "int_const 1190...(31 digits omitted)...8001"
+ },
+ "value": "0x5998b31359a55d48724c65cf09001221"
+ },
+ "src": "10893:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4251,
+ "nodeType": "ExpressionStatement",
+ "src": "10893:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4256,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4252,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "10958:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4254,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "37",
+ "id": 4253,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10973:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_7_by_1",
+ "typeString": "int_const 7"
+ },
+ "value": "7"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10958:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783538383562636164326233323264666334336538383630663963303138636635",
+ "id": 4255,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10978:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_117666465924103849245162796602282314997_by_1",
+ "typeString": "int_const 1176...(31 digits omitted)...4997"
+ },
+ "value": "0x5885bcad2b322dfc43e8860f9c018cf5"
+ },
+ "src": "10958:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4257,
+ "nodeType": "ExpressionStatement",
+ "src": "10958:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4262,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4258,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11023:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4260,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "38",
+ "id": 4259,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11038:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_8_by_1",
+ "typeString": "int_const 8"
+ },
+ "value": "8"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11023:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783537376239376161316665323232626234353266646631313162316630626532",
+ "id": 4261,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11043:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_116284564269392660122793483482959907810_by_1",
+ "typeString": "int_const 1162...(31 digits omitted)...7810"
+ },
+ "value": "0x577b97aa1fe222bb452fdf111b1f0be2"
+ },
+ "src": "11023:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4263,
+ "nodeType": "ExpressionStatement",
+ "src": "11023:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4268,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4264,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11088:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4266,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "39",
+ "id": 4265,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11103:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_9_by_1",
+ "typeString": "int_const 9"
+ },
+ "value": "9"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11088:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783536373963623565333537353633326535626161323765326239343966373034",
+ "id": 4267,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11108:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_114946000350526915053586759724674184964_by_1",
+ "typeString": "int_const 1149...(31 digits omitted)...4964"
+ },
+ "value": "0x5679cb5e3575632e5baa27e2b949f704"
+ },
+ "src": "11088:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4269,
+ "nodeType": "ExpressionStatement",
+ "src": "11088:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4274,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4270,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11153:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4272,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3130",
+ "id": 4271,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11167:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_10_by_1",
+ "typeString": "int_const 10"
+ },
+ "value": "10"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11153:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783535376665383234316233613331633833633733326631636466663461316335",
+ "id": 4273,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11173:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_113648509722420118059077800055408992709_by_1",
+ "typeString": "int_const 1136...(31 digits omitted)...2709"
+ },
+ "value": "0x557fe8241b3a31c83c732f1cdff4a1c5"
+ },
+ "src": "11153:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4275,
+ "nodeType": "ExpressionStatement",
+ "src": "11153:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4280,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4276,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11218:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4278,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3131",
+ "id": 4277,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11232:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_11_by_1",
+ "typeString": "int_const 11"
+ },
+ "value": "11"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11218:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783534386438363830323635303438373564366535396262653935666332613662",
+ "id": 4279,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11238:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_112389993498935521792135674271903787627_by_1",
+ "typeString": "int_const 1123...(31 digits omitted)...7627"
+ },
+ "value": "0x548d868026504875d6e59bbe95fc2a6b"
+ },
+ "src": "11218:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4281,
+ "nodeType": "ExpressionStatement",
+ "src": "11218:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4286,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4282,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11283:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4284,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3132",
+ "id": 4283,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11297:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_12_by_1",
+ "typeString": "int_const 12"
+ },
+ "value": "12"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11283:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783533613234363563653334376366333464303561383637633137646433303838",
+ "id": 4285,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11303:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_111168502869233775922830736618948472968_by_1",
+ "typeString": "int_const 1111...(31 digits omitted)...2968"
+ },
+ "value": "0x53a2465ce347cf34d05a867c17dd3088"
+ },
+ "src": "11283:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4287,
+ "nodeType": "ExpressionStatement",
+ "src": "11283:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4292,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4288,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11348:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4290,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3133",
+ "id": 4289,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11362:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_13_by_1",
+ "typeString": "int_const 13"
+ },
+ "value": "13"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11348:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783532626463653564636434666165643539633766353531316366386638616363",
+ "id": 4291,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11368:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_109982225368764407855921799421290842828_by_1",
+ "typeString": "int_const 1099...(31 digits omitted)...2828"
+ },
+ "value": "0x52bdce5dcd4faed59c7f5511cf8f8acc"
+ },
+ "src": "11348:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4293,
+ "nodeType": "ExpressionStatement",
+ "src": "11348:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4298,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4294,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11413:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4296,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3134",
+ "id": 4295,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11427:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_14_by_1",
+ "typeString": "int_const 14"
+ },
+ "value": "14"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11413:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783531646663623435336330376638646138313736303665373838356637633365",
+ "id": 4297,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11433:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_108829472672502945287330645348712414270_by_1",
+ "typeString": "int_const 1088...(31 digits omitted)...4270"
+ },
+ "value": "0x51dfcb453c07f8da817606e7885f7c3e"
+ },
+ "src": "11413:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4299,
+ "nodeType": "ExpressionStatement",
+ "src": "11413:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4304,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4300,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11478:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4302,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3135",
+ "id": 4301,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11492:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_15_by_1",
+ "typeString": "int_const 15"
+ },
+ "value": "15"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11478:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783531303765663662306135613262653866386666313535393064616133636365",
+ "id": 4303,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11498:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_107708669713100452055447769980296903886_by_1",
+ "typeString": "int_const 1077...(31 digits omitted)...3886"
+ },
+ "value": "0x5107ef6b0a5a2be8f8ff15590daa3cce"
+ },
+ "src": "11478:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4305,
+ "nodeType": "ExpressionStatement",
+ "src": "11478:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4310,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4306,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11543:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4308,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3136",
+ "id": 4307,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11557:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_16_by_1",
+ "typeString": "int_const 16"
+ },
+ "value": "16"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11543:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783530333566323431643665616530636437626163626131313939393364653762",
+ "id": 4309,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11563:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_106618344955764005172185288135427743355_by_1",
+ "typeString": "int_const 1066...(31 digits omitted)...3355"
+ },
+ "value": "0x5035f241d6eae0cd7bacba119993de7b"
+ },
+ "src": "11543:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4311,
+ "nodeType": "ExpressionStatement",
+ "src": "11543:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4316,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4312,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11608:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4314,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3137",
+ "id": 4313,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11622:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_17_by_1",
+ "typeString": "int_const 17"
+ },
+ "value": "17"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11608:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783466363938666539306435623533643533323137316531323130313634633636",
+ "id": 4315,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11628:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_105557121686023412139304113347686190182_by_1",
+ "typeString": "int_const 1055...(31 digits omitted)...0182"
+ },
+ "value": "0x4f698fe90d5b53d532171e1210164c66"
+ },
+ "src": "11608:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4317,
+ "nodeType": "ExpressionStatement",
+ "src": "11608:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4322,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4318,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11673:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4320,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3138",
+ "id": 4319,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11687:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_18_by_1",
+ "typeString": "int_const 18"
+ },
+ "value": "18"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11673:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783465613238386361323937613065366130396130656565323430653136633835",
+ "id": 4321,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11693:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_104523710186937447092740323392662629509_by_1",
+ "typeString": "int_const 1045...(31 digits omitted)...9509"
+ },
+ "value": "0x4ea288ca297a0e6a09a0eee240e16c85"
+ },
+ "src": "11673:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4323,
+ "nodeType": "ExpressionStatement",
+ "src": "11673:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4328,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4324,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11738:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4326,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3139",
+ "id": 4325,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11752:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_19_by_1",
+ "typeString": "int_const 19"
+ },
+ "value": "19"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11738:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783464653061313366646366356434323133666333393862613665336265636465",
+ "id": 4327,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11758:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_103516900699454640661508604755841903838_by_1",
+ "typeString": "int_const 1035...(31 digits omitted)...3838"
+ },
+ "value": "0x4de0a13fdcf5d4213fc398ba6e3becde"
+ },
+ "src": "11738:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4329,
+ "nodeType": "ExpressionStatement",
+ "src": "11738:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4334,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4330,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11803:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4332,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3230",
+ "id": 4331,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11817:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_20_by_1",
+ "typeString": "int_const 20"
+ },
+ "value": "20"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11803:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783464323361313435656566393166656330366230363134303830346334383038",
+ "id": 4333,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11823:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_102535557074135248197607991940341319688_by_1",
+ "typeString": "int_const 1025...(31 digits omitted)...9688"
+ },
+ "value": "0x4d23a145eef91fec06b06140804c4808"
+ },
+ "src": "11803:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4335,
+ "nodeType": "ExpressionStatement",
+ "src": "11803:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4340,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4336,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11868:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4338,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3231",
+ "id": 4337,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11882:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_21_by_1",
+ "typeString": "int_const 21"
+ },
+ "value": "21"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11868:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783463366235343330643463316565353532363437336462346165306631316465",
+ "id": 4339,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11888:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_101578611034720610581211104132006351326_by_1",
+ "typeString": "int_const 1015...(31 digits omitted)...1326"
+ },
+ "value": "0x4c6b5430d4c1ee5526473db4ae0f11de"
+ },
+ "src": "11868:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4341,
+ "nodeType": "ExpressionStatement",
+ "src": "11868:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4346,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4342,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11933:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4344,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3232",
+ "id": 4343,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11947:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_22_by_1",
+ "typeString": "int_const 22"
+ },
+ "value": "22"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11933:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783462623738383663323430353632656261313166343936336135336234323430",
+ "id": 4345,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11953:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_100645056984476184212709480501843018304_by_1",
+ "typeString": "int_const 1006...(31 digits omitted)...8304"
+ },
+ "value": "0x4bb7886c240562eba11f4963a53b4240"
+ },
+ "src": "11933:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4347,
+ "nodeType": "ExpressionStatement",
+ "src": "11933:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4352,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4348,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11998:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4350,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3233",
+ "id": 4349,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12012:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_23_by_1",
+ "typeString": "int_const 23"
+ },
+ "value": "23"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11998:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783462303830663366316362343931643264353231653065613435383335323165",
+ "id": 4351,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12018:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_99733947295139137817365771348103877150_by_1",
+ "typeString": "int_const 9973...(30 digits omitted)...7150"
+ },
+ "value": "0x4b080f3f1cb491d2d521e0ea4583521e"
+ },
+ "src": "11998:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4353,
+ "nodeType": "ExpressionStatement",
+ "src": "11998:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4358,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4354,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12063:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4356,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3234",
+ "id": 4355,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12077:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_24_by_1",
+ "typeString": "int_const 24"
+ },
+ "value": "24"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12063:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783461356362633936613035353839636234643836626531646233313638333634",
+ "id": 4357,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12083:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_98844388025919853370962885240683922276_by_1",
+ "typeString": "int_const 9884...(30 digits omitted)...2276"
+ },
+ "value": "0x4a5cbc96a05589cb4d86be1db3168364"
+ },
+ "src": "12063:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4359,
+ "nodeType": "ExpressionStatement",
+ "src": "12063:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4364,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4360,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12128:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4362,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3235",
+ "id": 4361,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12142:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_25_by_1",
+ "typeString": "int_const 25"
+ },
+ "value": "25"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12128:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783439623536366434303234333531373635386437386333333136326436656365",
+ "id": 4363,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12148:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_97975535026544040761524270664520658638_by_1",
+ "typeString": "int_const 9797...(30 digits omitted)...8638"
+ },
+ "value": "0x49b566d40243517658d78c33162d6ece"
+ },
+ "src": "12128:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4365,
+ "nodeType": "ExpressionStatement",
+ "src": "12128:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4370,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4366,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12193:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4368,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3236",
+ "id": 4367,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12207:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_26_by_1",
+ "typeString": "int_const 26"
+ },
+ "value": "26"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12193:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783439313165366130326535353037613330663934373338336664396133323736",
+ "id": 4369,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12213:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_97126590383947898169110886634107843190_by_1",
+ "typeString": "int_const 9712...(30 digits omitted)...3190"
+ },
+ "value": "0x4911e6a02e5507a30f947383fd9a3276"
+ },
+ "src": "12193:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4371,
+ "nodeType": "ExpressionStatement",
+ "src": "12193:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4376,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4372,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12258:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4374,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3237",
+ "id": 4373,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12272:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_27_by_1",
+ "typeString": "int_const 27"
+ },
+ "value": "27"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12258:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783438373231366332623331626534616463343164623861386435636330633838",
+ "id": 4375,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12278:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_96296799177093258962884240470124006536_by_1",
+ "typeString": "int_const 9629...(30 digits omitted)...6536"
+ },
+ "value": "0x487216c2b31be4adc41db8a8d5cc0c88"
+ },
+ "src": "12258:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4377,
+ "nodeType": "ExpressionStatement",
+ "src": "12258:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4382,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4378,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12323:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4380,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3238",
+ "id": 4379,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12337:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_28_by_1",
+ "typeString": "int_const 28"
+ },
+ "value": "28"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12323:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783437643564336663346137613162313838636433643738386235633565396663",
+ "id": 4381,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12343:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_95485446508569776991656929903084169724_by_1",
+ "typeString": "int_const 9548...(30 digits omitted)...9724"
+ },
+ "value": "0x47d5d3fc4a7a1b188cd3d788b5c5e9fc"
+ },
+ "src": "12323:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4383,
+ "nodeType": "ExpressionStatement",
+ "src": "12323:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4388,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4384,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12388:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4386,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3239",
+ "id": 4385,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12402:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_29_by_1",
+ "typeString": "int_const 29"
+ },
+ "value": "29"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12388:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783437336366636534383731613263343062633466396531633332623935356430",
+ "id": 4387,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12408:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_94691854785294407482575606759428806096_by_1",
+ "typeString": "int_const 9469...(30 digits omitted)...6096"
+ },
+ "value": "0x473cfce4871a2c40bc4f9e1c32b955d0"
+ },
+ "src": "12388:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4389,
+ "nodeType": "ExpressionStatement",
+ "src": "12388:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4394,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4390,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12453:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4392,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3330",
+ "id": 4391,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12467:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_30_by_1",
+ "typeString": "int_const 30"
+ },
+ "value": "30"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12453:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783436613737316361353738616238373834383538313065323835653331633637",
+ "id": 4393,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12473:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_93915381223786366589204098840684338279_by_1",
+ "typeString": "int_const 9391...(30 digits omitted)...8279"
+ },
+ "value": "0x46a771ca578ab878485810e285e31c67"
+ },
+ "src": "12453:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4395,
+ "nodeType": "ExpressionStatement",
+ "src": "12453:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4400,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4396,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12518:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4398,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3331",
+ "id": 4397,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12532:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_31_by_1",
+ "typeString": "int_const 31"
+ },
+ "value": "31"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12518:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783436313531343937313861656434633235386333373364633637366161373264",
+ "id": 4399,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12538:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_93155415558256953225873119289193178925_by_1",
+ "typeString": "int_const 9315...(30 digits omitted)...8925"
+ },
+ "value": "0x4615149718aed4c258c373dc676aa72d"
+ },
+ "src": "12518:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4401,
+ "nodeType": "ExpressionStatement",
+ "src": "12518:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4406,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4402,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12583:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4404,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3332",
+ "id": 4403,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12597:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_32_by_1",
+ "typeString": "int_const 32"
+ },
+ "value": "32"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12583:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783435383563386233663866653438396336653138333363613437383731333834",
+ "id": 4405,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12603:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_92411377932165840182246144520510444420_by_1",
+ "typeString": "int_const 9241...(30 digits omitted)...4420"
+ },
+ "value": "0x4585c8b3f8fe489c6e1833ca47871384"
+ },
+ "src": "12583:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4407,
+ "nodeType": "ExpressionStatement",
+ "src": "12583:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4412,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4408,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12648:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4410,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3333",
+ "id": 4409,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12662:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_33_by_1",
+ "typeString": "int_const 33"
+ },
+ "value": "33"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12648:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783434663937326631373465343165356566623765396436336332396365373335",
+ "id": 4411,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12668:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_91682716956007473314355351160117585717_by_1",
+ "typeString": "int_const 9168...(30 digits omitted)...5717"
+ },
+ "value": "0x44f972f174e41e5efb7e9d63c29ce735"
+ },
+ "src": "12648:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4413,
+ "nodeType": "ExpressionStatement",
+ "src": "12648:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4418,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4414,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12713:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4416,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3334",
+ "id": 4415,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12727:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_34_by_1",
+ "typeString": "int_const 34"
+ },
+ "value": "34"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12713:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783434366666393730626138366438623030626562303565636562663363346463",
+ "id": 4417,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12733:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_90968907915944387253011725111639917788_by_1",
+ "typeString": "int_const 9096...(30 digits omitted)...7788"
+ },
+ "value": "0x446ff970ba86d8b00beb05ecebf3c4dc"
+ },
+ "src": "12713:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4419,
+ "nodeType": "ExpressionStatement",
+ "src": "12713:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4424,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4420,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12778:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4422,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3335",
+ "id": 4421,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12792:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_35_by_1",
+ "typeString": "int_const 35"
+ },
+ "value": "35"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12778:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783433653934333865633838393731383132643666313938623563636161643936",
+ "id": 4423,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12798:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_90269451119533660821329652693370318230_by_1",
+ "typeString": "int_const 9026...(30 digits omitted)...8230"
+ },
+ "value": "0x43e9438ec88971812d6f198b5ccaad96"
+ },
+ "src": "12778:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4425,
+ "nodeType": "ExpressionStatement",
+ "src": "12778:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4430,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4426,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12843:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4428,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3336",
+ "id": 4427,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12857:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_36_by_1",
+ "typeString": "int_const 36"
+ },
+ "value": "36"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12843:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783433363533396431316666376265613635376165646462333934653830396566",
+ "id": 4429,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12863:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_89583870366228295001513378307654552047_by_1",
+ "typeString": "int_const 8958...(30 digits omitted)...2047"
+ },
+ "value": "0x436539d11ff7bea657aeddb394e809ef"
+ },
+ "src": "12843:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4431,
+ "nodeType": "ExpressionStatement",
+ "src": "12843:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4436,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4432,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12908:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4434,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3337",
+ "id": 4433,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12922:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_37_by_1",
+ "typeString": "int_const 37"
+ },
+ "value": "37"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12908:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783432653363356433653561393133343031643836663636646235643831633263",
+ "id": 4435,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12928:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_88911711531602529992461785625724984364_by_1",
+ "typeString": "int_const 8891...(30 digits omitted)...4364"
+ },
+ "value": "0x42e3c5d3e5a913401d86f66db5d81c2c"
+ },
+ "src": "12908:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4437,
+ "nodeType": "ExpressionStatement",
+ "src": "12908:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4442,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4438,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12973:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4440,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3338",
+ "id": 4439,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12987:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_38_by_1",
+ "typeString": "int_const 38"
+ },
+ "value": "38"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12973:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783432363464323339353330333037306561373236636265393864663632313734",
+ "id": 4441,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12993:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_88252541255370876457855407534749655412_by_1",
+ "typeString": "int_const 8825...(30 digits omitted)...5412"
+ },
+ "value": "0x4264d2395303070ea726cbe98df62174"
+ },
+ "src": "12973:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4443,
+ "nodeType": "ExpressionStatement",
+ "src": "12973:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4448,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4444,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13038:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4446,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3339",
+ "id": 4445,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13052:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_39_by_1",
+ "typeString": "int_const 39"
+ },
+ "value": "39"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13038:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783431653834613961353933626237313934633361363334396563616534656561",
+ "id": 4447,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13058:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_87605945724263666326070648659277401834_by_1",
+ "typeString": "int_const 8760...(30 digits omitted)...1834"
+ },
+ "value": "0x41e84a9a593bb7194c3a6349ecae4eea"
+ },
+ "src": "13038:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4449,
+ "nodeType": "ExpressionStatement",
+ "src": "13038:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4454,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4450,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13103:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4452,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3430",
+ "id": 4451,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13117:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_40_by_1",
+ "typeString": "int_const 40"
+ },
+ "value": "40"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13103:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783431366531623738356431336562613037613038663366313838373661356162",
+ "id": 4453,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13123:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_86971529541703351305061613312515941803_by_1",
+ "typeString": "int_const 8697...(30 digits omitted)...1803"
+ },
+ "value": "0x416e1b785d13eba07a08f3f18876a5ab"
+ },
+ "src": "13103:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4455,
+ "nodeType": "ExpressionStatement",
+ "src": "13103:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4460,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4456,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13168:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4458,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3431",
+ "id": 4457,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13182:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_41_by_1",
+ "typeString": "int_const 41"
+ },
+ "value": "41"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13168:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783430663633323266663338396434323362613964643765376537623765383039",
+ "id": 4459,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13188:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_86348914677009486241058826509159491593_by_1",
+ "typeString": "int_const 8634...(30 digits omitted)...1593"
+ },
+ "value": "0x40f6322ff389d423ba9dd7e7e7b7e809"
+ },
+ "src": "13168:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4461,
+ "nodeType": "ExpressionStatement",
+ "src": "13168:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4466,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4462,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13233:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4464,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3432",
+ "id": 4463,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13247:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_42_by_1",
+ "typeString": "int_const 42"
+ },
+ "value": "42"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13233:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783430383037636563386134363638383065636634313834353435643234306134",
+ "id": 4465,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13253:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_85737739487558329642902199100859629732_by_1",
+ "typeString": "int_const 8573...(30 digits omitted)...9732"
+ },
+ "value": "0x40807cec8a466880ecf4184545d240a4"
+ },
+ "src": "13233:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4467,
+ "nodeType": "ExpressionStatement",
+ "src": "13233:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4472,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4468,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13298:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4470,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3433",
+ "id": 4469,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13312:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_43_by_1",
+ "typeString": "int_const 43"
+ },
+ "value": "43"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13298:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783430306365613963653838613864336165363638653865613064396266303766",
+ "id": 4471,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13318:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_85137657807945661495348777847187304575_by_1",
+ "typeString": "int_const 8513...(30 digits omitted)...4575"
+ },
+ "value": "0x400cea9ce88a8d3ae668e8ea0d9bf07f"
+ },
+ "src": "13298:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4473,
+ "nodeType": "ExpressionStatement",
+ "src": "13298:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4478,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4474,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13363:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4476,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3434",
+ "id": 4475,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13377:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_44_by_1",
+ "typeString": "int_const 44"
+ },
+ "value": "44"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13363:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783366396236616538373732643463353530393165306564376466656130616331",
+ "id": 4477,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13383:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_84548338100757766960858976604962556609_by_1",
+ "typeString": "int_const 8454...(30 digits omitted)...6609"
+ },
+ "value": "0x3f9b6ae8772d4c55091e0ed7dfea0ac1"
+ },
+ "src": "13363:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4479,
+ "nodeType": "ExpressionStatement",
+ "src": "13363:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4484,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4480,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13428:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4482,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3435",
+ "id": 4481,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13442:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_45_by_1",
+ "typeString": "int_const 45"
+ },
+ "value": "45"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13428:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783366326265653235336664383435393466353462636161666163333833613133",
+ "id": 4483,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13448:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_83969462664053391893170430711084628499_by_1",
+ "typeString": "int_const 8396...(30 digits omitted)...8499"
+ },
+ "value": "0x3f2bee253fd84594f54bcaafac383a13"
+ },
+ "src": "13428:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4485,
+ "nodeType": "ExpressionStatement",
+ "src": "13428:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4490,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4486,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13493:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4488,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3436",
+ "id": 4487,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13507:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_46_by_1",
+ "typeString": "int_const 46"
+ },
+ "value": "46"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13493:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783365626536353465393532303862623932313063353735633038316335393538",
+ "id": 4489,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13513:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_83400726891105658214366213255032756568_by_1",
+ "typeString": "int_const 8340...(30 digits omitted)...6568"
+ },
+ "value": "0x3ebe654e95208bb9210c575c081c5958"
+ },
+ "src": "13493:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4491,
+ "nodeType": "ExpressionStatement",
+ "src": "13493:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4496,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4492,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13558:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4494,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3437",
+ "id": 4493,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13572:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_47_by_1",
+ "typeString": "int_const 47"
+ },
+ "value": "47"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13558:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783365353263316663353636353633356237386365316630356164353363303836",
+ "id": 4495,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13578:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_82841838578353379906637631327369937030_by_1",
+ "typeString": "int_const 8284...(30 digits omitted)...7030"
+ },
+ "value": "0x3e52c1fc5665635b78ce1f05ad53c086"
+ },
+ "src": "13558:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4497,
+ "nodeType": "ExpressionStatement",
+ "src": "13558:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4502,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4498,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13623:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4500,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3438",
+ "id": 4499,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13637:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_48_by_1",
+ "typeString": "int_const 48"
+ },
+ "value": "48"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13623:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783364653866363561633338383130316464663731386136663563316566663635",
+ "id": 4501,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13643:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_82292517277871139787215964642962505573_by_1",
+ "typeString": "int_const 8229...(30 digits omitted)...5573"
+ },
+ "value": "0x3de8f65ac388101ddf718a6f5c1eff65"
+ },
+ "src": "13623:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4503,
+ "nodeType": "ExpressionStatement",
+ "src": "13623:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4508,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4504,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13688:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4506,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3439",
+ "id": 4505,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13702:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_49_by_1",
+ "typeString": "int_const 49"
+ },
+ "value": "49"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13688:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783364383066353232643539626430623332386361303132646634636432643439",
+ "id": 4507,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13708:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_81752493690991422478947035708677500233_by_1",
+ "typeString": "int_const 8175...(30 digits omitted)...0233"
+ },
+ "value": "0x3d80f522d59bd0b328ca012df4cd2d49"
+ },
+ "src": "13688:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4509,
+ "nodeType": "ExpressionStatement",
+ "src": "13688:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4514,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4510,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13753:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4512,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3530",
+ "id": 4511,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13767:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_50_by_1",
+ "typeString": "int_const 50"
+ },
+ "value": "50"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13753:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783364316162313933313239656137326232333634386131363131363361383561",
+ "id": 4513,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13773:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_81221509100004039595242960659394308186_by_1",
+ "typeString": "int_const 8122...(30 digits omitted)...8186"
+ },
+ "value": "0x3d1ab193129ea72b23648a161163a85a"
+ },
+ "src": "13753:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4515,
+ "nodeType": "ExpressionStatement",
+ "src": "13753:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4520,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4516,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13818:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4518,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3531",
+ "id": 4517,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13832:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_51_by_1",
+ "typeString": "int_const 51"
+ },
+ "value": "51"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13818:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783363623631663638643332353736633133356239356366623533663736643735",
+ "id": 4519,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13838:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_80699314835121533818862589255787965813_by_1",
+ "typeString": "int_const 8069...(30 digits omitted)...5813"
+ },
+ "value": "0x3cb61f68d32576c135b95cfb53f76d75"
+ },
+ "src": "13818:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4521,
+ "nodeType": "ExpressionStatement",
+ "src": "13818:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4526,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4522,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13883:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4524,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3532",
+ "id": 4523,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13897:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_52_by_1",
+ "typeString": "int_const 52"
+ },
+ "value": "52"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13883:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783363353333326439663161616538353161333631396537376534636338343733",
+ "id": 4525,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13903:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_80185671774137293097540719362983101555_by_1",
+ "typeString": "int_const 8018...(30 digits omitted)...1555"
+ },
+ "value": "0x3c5332d9f1aae851a3619e77e4cc8473"
+ },
+ "src": "13883:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4527,
+ "nodeType": "ExpressionStatement",
+ "src": "13883:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4532,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4528,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13948:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4530,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3533",
+ "id": 4529,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13962:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_53_by_1",
+ "typeString": "int_const 53"
+ },
+ "value": "53"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13948:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783362663165303865646265326161313039653135323566363537353965663733",
+ "id": 4531,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13968:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_79680349872418462454459890475122421619_by_1",
+ "typeString": "int_const 7968...(30 digits omitted)...1619"
+ },
+ "value": "0x3bf1e08edbe2aa109e1525f65759ef73"
+ },
+ "src": "13948:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4533,
+ "nodeType": "ExpressionStatement",
+ "src": "13948:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4538,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4534,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14013:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4536,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3534",
+ "id": 4535,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14027:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_54_by_1",
+ "typeString": "int_const 54"
+ },
+ "value": "54"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14013:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783362393231643963666631336661326331393737343661336466633439313866",
+ "id": 4537,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14033:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_79183127721070807958897168260236874127_by_1",
+ "typeString": "int_const 7918...(30 digits omitted)...4127"
+ },
+ "value": "0x3b921d9cff13fa2c197746a3dfc4918f"
+ },
+ "src": "14013:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4539,
+ "nodeType": "ExpressionStatement",
+ "src": "14013:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4544,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4540,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14078:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4542,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3535",
+ "id": 4541,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14092:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_55_by_1",
+ "typeString": "int_const 55"
+ },
+ "value": "55"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14078:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783362333364663831383931306266633161356165666238663633616532616334",
+ "id": 4543,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14098:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_78693792131289586075780460739283528388_by_1",
+ "typeString": "int_const 7869...(30 digits omitted)...8388"
+ },
+ "value": "0x3b33df818910bfc1a5aefb8f63ae2ac4"
+ },
+ "src": "14078:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4545,
+ "nodeType": "ExpressionStatement",
+ "src": "14078:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4550,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4546,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14143:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4548,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3536",
+ "id": 4547,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14157:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_56_by_1",
+ "typeString": "int_const 56"
+ },
+ "value": "56"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14143:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783361643731633163373765333466613332613966313834393637656363626636",
+ "id": 4549,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14163:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_78212137743071079621363404241290185718_by_1",
+ "typeString": "int_const 7821...(30 digits omitted)...5718"
+ },
+ "value": "0x3ad71c1c77e34fa32a9f184967eccbf6"
+ },
+ "src": "14143:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4551,
+ "nodeType": "ExpressionStatement",
+ "src": "14143:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4556,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4552,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14208:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4554,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3537",
+ "id": 4553,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14222:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_57_by_1",
+ "typeString": "int_const 57"
+ },
+ "value": "57"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14208:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783361376263396162663263356262353365326637333834613861313635323161",
+ "id": 4555,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14228:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_77737966656605443744883248223254630938_by_1",
+ "typeString": "int_const 7773...(30 digits omitted)...0938"
+ },
+ "value": "0x3a7bc9abf2c5bb53e2f7384a8a16521a"
+ },
+ "src": "14208:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4557,
+ "nodeType": "ExpressionStatement",
+ "src": "14208:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4562,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4558,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14273:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4560,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3538",
+ "id": 4559,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14287:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_58_by_1",
+ "typeString": "int_const 58"
+ },
+ "value": "58"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14273:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783361323164656337653736333639373833613638613063363338356131633537",
+ "id": 4561,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14293:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_77271088084804339940770953226756955223_by_1",
+ "typeString": "int_const 7727...(30 digits omitted)...5223"
+ },
+ "value": "0x3a21dec7e76369783a68a0c6385a1c57"
+ },
+ "src": "14273:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4563,
+ "nodeType": "ExpressionStatement",
+ "src": "14273:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4568,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4564,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14338:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4566,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3539",
+ "id": 4565,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14352:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_59_by_1",
+ "typeString": "int_const 59"
+ },
+ "value": "59"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14338:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783339633935323564653663396364663763316331353763613461376136656533",
+ "id": 4567,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14358:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_76811318025537837376498009672859152099_by_1",
+ "typeString": "int_const 7681...(30 digits omitted)...2099"
+ },
+ "value": "0x39c9525de6c9cdf7c1c157ca4a7a6ee3"
+ },
+ "src": "14338:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4569,
+ "nodeType": "ExpressionStatement",
+ "src": "14338:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4574,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4570,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14403:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4572,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3630",
+ "id": 4571,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14417:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_60_by_1",
+ "typeString": "int_const 60"
+ },
+ "value": "60"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14403:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783339373231626164336463383564313234306666303139306530616461616333",
+ "id": 4573,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14423:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_76358478952265398947834068366573546179_by_1",
+ "typeString": "int_const 7635...(30 digits omitted)...6179"
+ },
+ "value": "0x39721bad3dc85d1240ff0190e0adaac3"
+ },
+ "src": "14403:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4575,
+ "nodeType": "ExpressionStatement",
+ "src": "14403:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4580,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4576,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14468:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4578,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3631",
+ "id": 4577,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14482:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_61_by_1",
+ "typeString": "int_const 61"
+ },
+ "value": "61"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14468:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783339316333323433343464333234386630343639656232386464336437376530",
+ "id": 4579,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14488:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_75912399521846487627533653549497808864_by_1",
+ "typeString": "int_const 7591...(30 digits omitted)...8864"
+ },
+ "value": "0x391c324344d3248f0469eb28dd3d77e0"
+ },
+ "src": "14468:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4581,
+ "nodeType": "ExpressionStatement",
+ "src": "14468:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4586,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4582,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14533:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4584,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3632",
+ "id": 4583,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14547:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_62_by_1",
+ "typeString": "int_const 62"
+ },
+ "value": "62"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14533:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783338633738646637653363373936323739666234666638343339346162336461",
+ "id": 4585,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14553:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_75472914298408358042964121331947975642_by_1",
+ "typeString": "int_const 7547...(30 digits omitted)...5642"
+ },
+ "value": "0x38c78df7e3c796279fb4ff84394ab3da"
+ },
+ "src": "14533:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4587,
+ "nodeType": "ExpressionStatement",
+ "src": "14533:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4592,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4588,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14598:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4590,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3633",
+ "id": 4589,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14612:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_63_by_1",
+ "typeString": "int_const 63"
+ },
+ "value": "63"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14598:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783338373432366561343633386165396161653038303439643335353463323061",
+ "id": 4591,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14618:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_75039863492232771067353298784442696202_by_1",
+ "typeString": "int_const 7503...(30 digits omitted)...6202"
+ },
+ "value": "0x387426ea4638ae9aae08049d3554c20a"
+ },
+ "src": "14598:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4593,
+ "nodeType": "ExpressionStatement",
+ "src": "14598:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4598,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4594,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14663:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4596,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3634",
+ "id": 4595,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14677:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_64_by_1",
+ "typeString": "int_const 64"
+ },
+ "value": "64"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14663:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783338323166353764626432373633323536633161393962626432303531333738",
+ "id": 4597,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14683:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_74613092712700430304450998910501327736_by_1",
+ "typeString": "int_const 7461...(30 digits omitted)...7736"
+ },
+ "value": "0x3821f57dbd2763256c1a99bbd2051378"
+ },
+ "src": "14663:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4599,
+ "nodeType": "ExpressionStatement",
+ "src": "14663:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4604,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4600,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14728:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4602,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3635",
+ "id": 4601,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14742:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_65_by_1",
+ "typeString": "int_const 65"
+ },
+ "value": "65"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14728:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783337643066323536636234366138633932666636326662626566323839363938",
+ "id": 4603,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14748:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_74192452734402555957346115989134677656_by_1",
+ "typeString": "int_const 7419...(30 digits omitted)...7656"
+ },
+ "value": "0x37d0f256cb46a8c92ff62fbbef289698"
+ },
+ "src": "14728:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4605,
+ "nodeType": "ExpressionStatement",
+ "src": "14728:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4610,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4606,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14793:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4608,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3636",
+ "id": 4607,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14807:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_66_by_1",
+ "typeString": "int_const 66"
+ },
+ "value": "66"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14793:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783337383131363538353931666663376162646431666561663363656639623733",
+ "id": 4609,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14813:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_73777799275593782240843075749260794739_by_1",
+ "typeString": "int_const 7377...(30 digits omitted)...4739"
+ },
+ "value": "0x37811658591ffc7abdd1feaf3cef9b73"
+ },
+ "src": "14793:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4611,
+ "nodeType": "ExpressionStatement",
+ "src": "14793:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4616,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4612,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14858:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4614,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3637",
+ "id": 4613,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14872:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_67_by_1",
+ "typeString": "int_const 67"
+ },
+ "value": "67"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14858:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783337333235616131306539653832663764663066333830663739393731353462",
+ "id": 4615,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14878:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_73368992788220026735092049811183441227_by_1",
+ "typeString": "int_const 7336...(30 digits omitted)...1227"
+ },
+ "value": "0x37325aa10e9e82f7df0f380f7997154b"
+ },
+ "src": "14858:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4617,
+ "nodeType": "ExpressionStatement",
+ "src": "14858:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4622,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4618,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14923:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4620,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3638",
+ "id": 4619,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14937:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_68_by_1",
+ "typeString": "int_const 68"
+ },
+ "value": "68"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14923:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783336653462383838636662343038643837336239613830643433393331316336",
+ "id": 4621,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14943:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_72965898258809617135734979750291247558_by_1",
+ "typeString": "int_const 7296...(30 digits omitted)...7558"
+ },
+ "value": "0x36e4b888cfb408d873b9a80d439311c6"
+ },
+ "src": "14923:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4623,
+ "nodeType": "ExpressionStatement",
+ "src": "14923:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4628,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4624,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14988:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4626,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3639",
+ "id": 4625,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15002:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_69_by_1",
+ "typeString": "int_const 69"
+ },
+ "value": "69"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14988:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783336393832393965353966346262396465363435666339623038633634636361",
+ "id": 4627,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15008:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_72568385019566207677944681290529131722_by_1",
+ "typeString": "int_const 7256...(30 digits omitted)...1722"
+ },
+ "value": "0x3698299e59f4bb9de645fc9b08c64cca"
+ },
+ "src": "14988:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4629,
+ "nodeType": "ExpressionStatement",
+ "src": "14988:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4634,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4630,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15053:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4632,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3730",
+ "id": 4631,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15067:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_70_by_1",
+ "typeString": "int_const 70"
+ },
+ "value": "70"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15053:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783336346361376135303132636236303330323362353764643365626664353064",
+ "id": 4633,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15073:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_72176326569048265991235723170299237645_by_1",
+ "typeString": "int_const 7217...(30 digits omitted)...7645"
+ },
+ "value": "0x364ca7a5012cb603023b57dd3ebfd50d"
+ },
+ "src": "15053:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4635,
+ "nodeType": "ExpressionStatement",
+ "src": "15053:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4640,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4636,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15118:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4638,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3731",
+ "id": 4637,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15132:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_71_by_1",
+ "typeString": "int_const 71"
+ },
+ "value": "71"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15118:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783336303232633932383931356237373861623162303661616565376536316434",
+ "id": 4639,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15138:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_71789600401862514754895875938526847444_by_1",
+ "typeString": "int_const 7178...(30 digits omitted)...7444"
+ },
+ "value": "0x36022c928915b778ab1b06aaee7e61d4"
+ },
+ "src": "15118:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4641,
+ "nodeType": "ExpressionStatement",
+ "src": "15118:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4646,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4642,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15183:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4644,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3732",
+ "id": 4643,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15197:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_72_by_1",
+ "typeString": "int_const 72"
+ },
+ "value": "72"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15183:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783335623862323864316137336463323735303066666533353535396363303238",
+ "id": 4645,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15203:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_71408087846837990426587462311123664936_by_1",
+ "typeString": "int_const 7140...(30 digits omitted)...4936"
+ },
+ "value": "0x35b8b28d1a73dc27500ffe35559cc028"
+ },
+ "src": "15183:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4647,
+ "nodeType": "ExpressionStatement",
+ "src": "15183:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4652,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4648,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15248:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4650,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3733",
+ "id": 4649,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15262:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_73_by_1",
+ "typeString": "int_const 73"
+ },
+ "value": "73"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15248:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783335373033336539353166653235306563356562346536303935353133326437",
+ "id": 4651,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15268:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_71031673913183621970866398796903953111_by_1",
+ "typeString": "int_const 7103...(30 digits omitted)...3111"
+ },
+ "value": "0x357033e951fe250ec5eb4e60955132d7"
+ },
+ "src": "15248:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4653,
+ "nodeType": "ExpressionStatement",
+ "src": "15248:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4658,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4654,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15313:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4656,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3734",
+ "id": 4655,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15327:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_74_by_1",
+ "typeString": "int_const 74"
+ },
+ "value": "74"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15313:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783335323861623238363739333465336132316235343132653463346638383831",
+ "id": 4657,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15333:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_70660247144165696899266624685710739585_by_1",
+ "typeString": "int_const 7066...(30 digits omitted)...9585"
+ },
+ "value": "0x3528ab2867934e3a21b5412e4c4f8881"
+ },
+ "src": "15313:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4659,
+ "nodeType": "ExpressionStatement",
+ "src": "15313:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4664,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4660,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15378:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4662,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3735",
+ "id": 4661,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15392:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_75_by_1",
+ "typeString": "int_const 75"
+ },
+ "value": "75"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15378:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783334653231326636366335353035376639363736633830303934613631643539",
+ "id": 4663,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15398:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_70293699477872506394924034036542610777_by_1",
+ "typeString": "int_const 7029...(30 digits omitted)...0777"
+ },
+ "value": "0x34e212f66c55057f9676c80094a61d59"
+ },
+ "src": "15378:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4665,
+ "nodeType": "ExpressionStatement",
+ "src": "15378:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4670,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4666,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15443:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4668,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3736",
+ "id": 4667,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15457:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_76_by_1",
+ "typeString": "int_const 76"
+ },
+ "value": "76"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15443:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783334396336363238396535623363346235343063323466343266613462396262",
+ "id": 4669,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15463:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_69931926114662060074913956973764721083_by_1",
+ "typeString": "int_const 6993...(30 digits omitted)...1083"
+ },
+ "value": "0x349c66289e5b3c4b540c24f42fa4b9bb"
+ },
+ "src": "15443:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4671,
+ "nodeType": "ExpressionStatement",
+ "src": "15443:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4676,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4672,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15508:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4674,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3737",
+ "id": 4673,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15522:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_77_by_1",
+ "typeString": "int_const 77"
+ },
+ "value": "77"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15508:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783334353739666262643063373333613963386436616636623066376430306637",
+ "id": 4675,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15528:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_69574825390915228431314065557192245495_by_1",
+ "typeString": "int_const 6957...(30 digits omitted)...5495"
+ },
+ "value": "0x34579fbbd0c733a9c8d6af6b0f7d00f7"
+ },
+ "src": "15508:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4677,
+ "nodeType": "ExpressionStatement",
+ "src": "15508:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4682,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4678,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15573:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4680,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3738",
+ "id": 4679,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15587:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_78_by_1",
+ "typeString": "int_const 78"
+ },
+ "value": "78"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15573:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783334313362616432653731323238386239323462353838326235623336396266",
+ "id": 4681,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15593:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_69222298658741183724931927301015431615_by_1",
+ "typeString": "int_const 6922...(30 digits omitted)...1615"
+ },
+ "value": "0x3413bad2e712288b924b5882b5b369bf"
+ },
+ "src": "15573:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4683,
+ "nodeType": "ExpressionStatement",
+ "src": "15573:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4688,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4684,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15638:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4686,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3739",
+ "id": 4685,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15652:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_79_by_1",
+ "typeString": "int_const 79"
+ },
+ "value": "79"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15638:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783333643062326235363238363531306566373330653231336637316631326539",
+ "id": 4687,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15658:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_68874250171304728554080761972223054569_by_1",
+ "typeString": "int_const 6887...(30 digits omitted)...4569"
+ },
+ "value": "0x33d0b2b56286510ef730e213f71f12e9"
+ },
+ "src": "15638:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4689,
+ "nodeType": "ExpressionStatement",
+ "src": "15638:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4694,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4690,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15703:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4692,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3830",
+ "id": 4691,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15717:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_80_by_1",
+ "typeString": "int_const 80"
+ },
+ "value": "80"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15703:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783333386538326365303065323439363236326336343435373533356261316131",
+ "id": 4693,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15723:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_68530586973466171479838674269845037473_by_1",
+ "typeString": "int_const 6853...(30 digits omitted)...7473"
+ },
+ "value": "0x338e82ce00e2496262c64457535ba1a1"
+ },
+ "src": "15703:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4695,
+ "nodeType": "ExpressionStatement",
+ "src": "15703:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4700,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4696,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15768:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4698,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3831",
+ "id": 4697,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15782:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_81_by_1",
+ "typeString": "int_const 81"
+ },
+ "value": "81"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15768:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783333346432366139366233373362623763326638656131383237663237613932",
+ "id": 4699,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15788:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_68191218797443963900028789779252542098_by_1",
+ "typeString": "int_const 6819...(30 digits omitted)...2098"
+ },
+ "value": "0x334d26a96b373bb7c2f8ea1827f27a92"
+ },
+ "src": "15768:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4701,
+ "nodeType": "ExpressionStatement",
+ "src": "15768:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4706,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4702,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15833:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4704,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3832",
+ "id": 4703,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15847:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_82_by_1",
+ "typeString": "int_const 82"
+ },
+ "value": "82"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15833:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783333306339396634663432313134363965303062336531386333313437356561",
+ "id": 4705,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15853:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_67856057963228472984547093013750642154_by_1",
+ "typeString": "int_const 6785...(30 digits omitted)...2154"
+ },
+ "value": "0x330c99f4f4211469e00b3e18c31475ea"
+ },
+ "src": "15833:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4707,
+ "nodeType": "ExpressionStatement",
+ "src": "15833:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4712,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4708,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15898:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4710,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3833",
+ "id": 4709,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15912:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_83_by_1",
+ "typeString": "int_const 83"
+ },
+ "value": "83"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15898:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783332636364383764363438363039343939396337643565366633333233376438",
+ "id": 4711,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15918:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_67525019283492142426218937050010367960_by_1",
+ "typeString": "int_const 6752...(30 digits omitted)...7960"
+ },
+ "value": "0x32ccd87d6486094999c7d5e6f33237d8"
+ },
+ "src": "15898:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4713,
+ "nodeType": "ExpressionStatement",
+ "src": "15898:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4718,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4714,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15963:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4716,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3834",
+ "id": 4715,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15977:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_84_by_1",
+ "typeString": "int_const 84"
+ },
+ "value": "84"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15963:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783332386464653264643631376236363635613265383535366632353063316166",
+ "id": 4717,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15983:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_67198019972756986907927497888446333359_by_1",
+ "typeString": "int_const 6719...(30 digits omitted)...3359"
+ },
+ "value": "0x328dde2dd617b6665a2e8556f250c1af"
+ },
+ "src": "15963:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4719,
+ "nodeType": "ExpressionStatement",
+ "src": "15963:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4724,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4720,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16028:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4722,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3835",
+ "id": 4721,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16042:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_85_by_1",
+ "typeString": "int_const 85"
+ },
+ "value": "85"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16028:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783332346661373065396164633237306638323632373535616635613939616639",
+ "id": 4723,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16048:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_66874979560594969707697340554641251065_by_1",
+ "typeString": "int_const 6687...(30 digits omitted)...1065"
+ },
+ "value": "0x324fa70e9adc270f8262755af5a99af9"
+ },
+ "src": "16028:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4725,
+ "nodeType": "ExpressionStatement",
+ "src": "16028:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4730,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4726,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16093:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4728,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3836",
+ "id": 4727,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16107:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_86_by_1",
+ "typeString": "int_const 86"
+ },
+ "value": "86"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16093:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783332313232663434333131303631316361353130343066343166613665316533",
+ "id": 4729,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16113:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_66555819808650410033300276716637708771_by_1",
+ "typeString": "int_const 6655...(30 digits omitted)...8771"
+ },
+ "value": "0x32122f443110611ca51040f41fa6e1e3"
+ },
+ "src": "16093:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4731,
+ "nodeType": "ExpressionStatement",
+ "src": "16093:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4736,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4732,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16158:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4734,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3837",
+ "id": 4733,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16172:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_87_by_1",
+ "typeString": "int_const 87"
+ },
+ "value": "87"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16158:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783331643537333065343263303833313438326630663134383563343236336438",
+ "id": 4735,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16178:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_66240464631286234612917249162896106456_by_1",
+ "typeString": "int_const 6624...(30 digits omitted)...6456"
+ },
+ "value": "0x31d5730e42c0831482f0f1485c4263d8"
+ },
+ "src": "16158:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4737,
+ "nodeType": "ExpressionStatement",
+ "src": "16158:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4742,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4738,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16223:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4740,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3838",
+ "id": 4739,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16237:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_88_by_1",
+ "typeString": "int_const 88"
+ },
+ "value": "88"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16223:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783331393936656336623037623461383334323162356562633461623465316631",
+ "id": 4741,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16243:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_65928840019667697388313232298873250289_by_1",
+ "typeString": "int_const 6592...(30 digits omitted)...0289"
+ },
+ "value": "0x31996ec6b07b4a83421b5ebc4ab4e1f1"
+ },
+ "src": "16223:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4743,
+ "nodeType": "ExpressionStatement",
+ "src": "16223:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4748,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4744,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16288:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4746,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3839",
+ "id": 4745,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16302:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_89_by_1",
+ "typeString": "int_const 89"
+ },
+ "value": "89"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16288:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783331356531656530613638666634366262343365633262383530333265383736",
+ "id": 4747,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16308:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_65620873969108206581452393912976205942_by_1",
+ "typeString": "int_const 6562...(30 digits omitted)...5942"
+ },
+ "value": "0x315e1ee0a68ff46bb43ec2b85032e876"
+ },
+ "src": "16288:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4749,
+ "nodeType": "ExpressionStatement",
+ "src": "16288:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4754,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4750,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16353:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4752,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3930",
+ "id": 4751,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16367:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_90_by_1",
+ "typeString": "int_const 90"
+ },
+ "value": "90"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16353:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783331323337666537626334646561636636373735623965666131613134356638",
+ "id": 4753,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16373:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_65316496409512179290702222053435590136_by_1",
+ "typeString": "int_const 6531...(30 digits omitted)...0136"
+ },
+ "value": "0x31237fe7bc4deacf6775b9efa1a145f8"
+ },
+ "src": "16353:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4755,
+ "nodeType": "ExpressionStatement",
+ "src": "16353:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4760,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4756,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16418:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4758,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3931",
+ "id": 4757,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16432:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_91_by_1",
+ "typeString": "int_const 91"
+ },
+ "value": "91"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16418:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783330653938653766316363356133353665343436323761363937326561326666",
+ "id": 4759,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16438:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_65015639138759444595668739676303172351_by_1",
+ "typeString": "int_const 6501...(30 digits omitted)...2351"
+ },
+ "value": "0x30e98e7f1cc5a356e44627a6972ea2ff"
+ },
+ "src": "16418:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4761,
+ "nodeType": "ExpressionStatement",
+ "src": "16418:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4766,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4762,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16483:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4764,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3932",
+ "id": 4763,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16497:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_92_by_1",
+ "typeString": "int_const 92"
+ },
+ "value": "92"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16483:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783330623034373630623839313765633734323035613330303236353065633035",
+ "id": 4765,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16503:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_64718235758884686944788529404074585093_by_1",
+ "typeString": "int_const 6471...(30 digits omitted)...5093"
+ },
+ "value": "0x30b04760b8917ec74205a3002650ec05"
+ },
+ "src": "16483:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4767,
+ "nodeType": "ExpressionStatement",
+ "src": "16483:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4772,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4768,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16548:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4770,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3933",
+ "id": 4769,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16562:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_93_by_1",
+ "typeString": "int_const 93"
+ },
+ "value": "93"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16548:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783330373761373563383033343638653931333263653063663332323432343164",
+ "id": 4771,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16568:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_64424221614913808353797169251126354973_by_1",
+ "typeString": "int_const 6442...(30 digits omitted)...4973"
+ },
+ "value": "0x3077a75c803468e9132ce0cf3224241d"
+ },
+ "src": "16548:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4773,
+ "nodeType": "ExpressionStatement",
+ "src": "16548:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4778,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4774,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16613:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4776,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3934",
+ "id": 4775,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16627:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_94_by_1",
+ "typeString": "int_const 94"
+ },
+ "value": "94"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16613:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783330336661623537613661323735633336663139636461396261636536363761",
+ "id": 4777,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16633:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_64133533736226932951740123178454640250_by_1",
+ "typeString": "int_const 6413...(30 digits omitted)...0250"
+ },
+ "value": "0x303fab57a6a275c36f19cda9bace667a"
+ },
+ "src": "16613:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4779,
+ "nodeType": "ExpressionStatement",
+ "src": "16613:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4784,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4780,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16678:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4782,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3935",
+ "id": 4781,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16692:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_95_by_1",
+ "typeString": "int_const 95"
+ },
+ "value": "95"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16678:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783330303835303462656238646362643263663362633166366435613036346630",
+ "id": 4783,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16698:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_63846110780325119601596992296297981168_by_1",
+ "typeString": "int_const 6384...(30 digits omitted)...1168"
+ },
+ "value": "0x3008504beb8dcbd2cf3bc1f6d5a064f0"
+ },
+ "src": "16678:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4785,
+ "nodeType": "ExpressionStatement",
+ "src": "16678:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4790,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4786,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16743:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4788,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3936",
+ "id": 4787,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16757:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_96_by_1",
+ "typeString": "int_const 96"
+ },
+ "value": "96"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16743:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783266643139333436656431376461633631323139636530633263356163346230",
+ "id": 4789,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16763:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_63561892978884723546060567414717465776_by_1",
+ "typeString": "int_const 6356...(30 digits omitted)...5776"
+ },
+ "value": "0x2fd19346ed17dac61219ce0c2c5ac4b0"
+ },
+ "src": "16743:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4791,
+ "nodeType": "ExpressionStatement",
+ "src": "16743:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4796,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4792,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16808:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4794,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3937",
+ "id": 4793,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16822:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_97_by_1",
+ "typeString": "int_const 97"
+ },
+ "value": "97"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16808:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783266396237313639383038633332346235383532666433643534626139373134",
+ "id": 4795,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16828:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_63280822085989789325487105680707589908_by_1",
+ "typeString": "int_const 6328...(30 digits omitted)...9908"
+ },
+ "value": "0x2f9b7169808c324b5852fd3d54ba9714"
+ },
+ "src": "16808:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4797,
+ "nodeType": "ExpressionStatement",
+ "src": "16808:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4802,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4798,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16873:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4800,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3938",
+ "id": 4799,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16887:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_98_by_1",
+ "typeString": "int_const 98"
+ },
+ "value": "98"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16873:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783266363565376537313163663462303634656561396330386362646164353734",
+ "id": 4801,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16893:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_63002841328438895053366731000363275636_by_1",
+ "typeString": "int_const 6300...(30 digits omitted)...5636"
+ },
+ "value": "0x2f65e7e711cf4b064eea9c08cbdad574"
+ },
+ "src": "16873:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4803,
+ "nodeType": "ExpressionStatement",
+ "src": "16873:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4808,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4804,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16938:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4806,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3939",
+ "id": 4805,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16952:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_99_by_1",
+ "typeString": "int_const 99"
+ },
+ "value": "99"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16938:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783266333066343035303933303432646466663861323531623662663664313033",
+ "id": 4807,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16958:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_62727895358028530630619015085479612675_by_1",
+ "typeString": "int_const 6272...(30 digits omitted)...2675"
+ },
+ "value": "0x2f30f405093042ddff8a251b6bf6d103"
+ },
+ "src": "16938:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4809,
+ "nodeType": "ExpressionStatement",
+ "src": "16938:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4814,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4810,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17003:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4812,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313030",
+ "id": 4811,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17016:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_100_by_1",
+ "typeString": "int_const 100"
+ },
+ "value": "100"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17003:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783265666339333161333735306632653862666533323365646665303337353734",
+ "id": 4813,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17023:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_62455930205720405594293470980571624820_by_1",
+ "typeString": "int_const 6245...(30 digits omitted)...4820"
+ },
+ "value": "0x2efc931a3750f2e8bfe323edfe037574"
+ },
+ "src": "17003:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4815,
+ "nodeType": "ExpressionStatement",
+ "src": "17003:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4820,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4816,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17068:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4818,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313031",
+ "id": 4817,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17081:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_101_by_1",
+ "typeString": "int_const 101"
+ },
+ "value": "101"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17068:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783265633863323865343664626535366439383638353237383333393430306362",
+ "id": 4819,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17088:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_62186893237605070014470966239378538699_by_1",
+ "typeString": "int_const 6218...(30 digits omitted)...8699"
+ },
+ "value": "0x2ec8c28e46dbe56d98685278339400cb"
+ },
+ "src": "17068:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4821,
+ "nodeType": "ExpressionStatement",
+ "src": "17068:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4826,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4822,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17133:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4824,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313032",
+ "id": 4823,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17146:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_102_by_1",
+ "typeString": "int_const 102"
+ },
+ "value": "102"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17133:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783265393537666439333363333932366438613539396236303233373962383531",
+ "id": 4825,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17153:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_61920733112578916349615492109849704529_by_1",
+ "typeString": "int_const 6192...(30 digits omitted)...4529"
+ },
+ "value": "0x2e957fd933c3926d8a599b602379b851"
+ },
+ "src": "17133:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4827,
+ "nodeType": "ExpressionStatement",
+ "src": "17133:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4832,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4828,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17198:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4830,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313033",
+ "id": 4829,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17211:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_103_by_1",
+ "typeString": "int_const 103"
+ },
+ "value": "103"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17198:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783265363263383832633763396564343437333431323730326630386261306535",
+ "id": 4831,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17218:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_61657399741656031957349998364069699813_by_1",
+ "typeString": "int_const 6165...(30 digits omitted)...9813"
+ },
+ "value": "0x2e62c882c7c9ed4473412702f08ba0e5"
+ },
+ "src": "17198:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4833,
+ "nodeType": "ExpressionStatement",
+ "src": "17198:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4838,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4834,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17263:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4836,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313034",
+ "id": 4835,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17276:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_104_by_1",
+ "typeString": "int_const 104"
+ },
+ "value": "104"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17263:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783265333039613232316331326261333631653365643639353136376665656532",
+ "id": 4837,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17283:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_61396844248840510020197488843164741346_by_1",
+ "typeString": "int_const 6139...(30 digits omitted)...1346"
+ },
+ "value": "0x2e309a221c12ba361e3ed695167feee2"
+ },
+ "src": "17263:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4839,
+ "nodeType": "ExpressionStatement",
+ "src": "17263:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4844,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4840,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17328:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4842,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313035",
+ "id": 4841,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17341:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_105_by_1",
+ "typeString": "int_const 105"
+ },
+ "value": "105"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17328:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783264666566323564316638363561653138646430376366656134626365613130",
+ "id": 4843,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17348:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_61139018933488718567153792494864230928_by_1",
+ "typeString": "int_const 6113...(30 digits omitted)...0928"
+ },
+ "value": "0x2dfef25d1f865ae18dd07cfea4bcea10"
+ },
+ "src": "17328:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4845,
+ "nodeType": "ExpressionStatement",
+ "src": "17328:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4850,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4846,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17393:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4848,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313036",
+ "id": 4847,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17406:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_106_by_1",
+ "typeString": "int_const 106"
+ },
+ "value": "106"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17393:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783264636463656538323163646338306465636330326334343334346165623331",
+ "id": 4849,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17413:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_60883877234094689345243041491992636209_by_1",
+ "typeString": "int_const 6088...(30 digits omitted)...6209"
+ },
+ "value": "0x2dcdcee821cdc80decc02c44344aeb31"
+ },
+ "src": "17393:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4851,
+ "nodeType": "ExpressionStatement",
+ "src": "17393:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4856,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4852,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17458:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4854,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313037",
+ "id": 4853,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17471:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_107_by_1",
+ "typeString": "int_const 107"
+ },
+ "value": "107"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17458:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783264396432643835363262333439343464306232303162623837323630633833",
+ "id": 4855,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17478:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_60631373693435235627049349068288822403_by_1",
+ "typeString": "int_const 6063...(30 digits omitted)...2403"
+ },
+ "value": "0x2d9d2d8562b34944d0b201bb87260c83"
+ },
+ "src": "17458:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4857,
+ "nodeType": "ExpressionStatement",
+ "src": "17458:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4862,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4858,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17523:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4860,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313038",
+ "id": 4859,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17536:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_108_by_1",
+ "typeString": "int_const 108"
+ },
+ "value": "108"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17523:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783264366430633034613562363261326334323633363330383636396237323961",
+ "id": 4861,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17543:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_60381463925014654644808174288326324890_by_1",
+ "typeString": "int_const 6038...(30 digits omitted)...4890"
+ },
+ "value": "0x2d6d0c04a5b62a2c42636308669b729a"
+ },
+ "src": "17523:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4863,
+ "nodeType": "ExpressionStatement",
+ "src": "17523:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4868,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4864,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17588:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4866,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313039",
+ "id": 4865,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17601:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_109_by_1",
+ "typeString": "int_const 109"
+ },
+ "value": "109"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17588:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783264336436383432633961323335353137666335613033333236393135323866",
+ "id": 4867,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17608:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_60134104580751929226866781633165480591_by_1",
+ "typeString": "int_const 6013...(30 digits omitted)...0591"
+ },
+ "value": "0x2d3d6842c9a235517fc5a0332691528f"
+ },
+ "src": "17588:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4869,
+ "nodeType": "ExpressionStatement",
+ "src": "17588:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4874,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4870,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17653:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4872,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313130",
+ "id": 4871,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17666:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_110_by_1",
+ "typeString": "int_const 110"
+ },
+ "value": "110"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17653:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783264306534303239363366653165613238333461626334303863343337633130",
+ "id": 4873,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17673:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_59889253319856226458538603217703631888_by_1",
+ "typeString": "int_const 5988...(30 digits omitted)...1888"
+ },
+ "value": "0x2d0e402963fe1ea2834abc408c437c10"
+ },
+ "src": "17653:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4875,
+ "nodeType": "ExpressionStatement",
+ "src": "17653:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4880,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4876,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17718:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4878,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313131",
+ "id": 4877,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17731:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_111_by_1",
+ "typeString": "int_const 111"
+ },
+ "value": "111"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17718:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783263646639316165363032363437393038616666393735653464366132613863",
+ "id": 4879,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17738:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_59646868778839210021497828354615290508_by_1",
+ "typeString": "int_const 5964...(30 digits omitted)...0508"
+ },
+ "value": "0x2cdf91ae602647908aff975e4d6a2a8c"
+ },
+ "src": "17718:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4881,
+ "nodeType": "ExpressionStatement",
+ "src": "17718:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4886,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4882,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17783:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4884,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313132",
+ "id": 4883,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17796:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_112_by_1",
+ "typeString": "int_const 112"
+ },
+ "value": "112"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17783:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783263623135616433613165623635663664373461373564613039613162366335",
+ "id": 4885,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17803:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_59406910542615247719403943326214371013_by_1",
+ "typeString": "int_const 5940...(30 digits omitted)...1013"
+ },
+ "value": "0x2cb15ad3a1eb65f6d74a75da09a1b6c5"
+ },
+ "src": "17783:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4887,
+ "nodeType": "ExpressionStatement",
+ "src": "17783:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4892,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4888,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17848:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4890,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313133",
+ "id": 4889,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17861:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_113_by_1",
+ "typeString": "int_const 113"
+ },
+ "value": "113"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17848:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783263383339396136616238653937373464366663666633373364323130373237",
+ "id": 4891,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17868:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_59169339116643016279047957521648125735_by_1",
+ "typeString": "int_const 5916...(30 digits omitted)...5735"
+ },
+ "value": "0x2c8399a6ab8e9774d6fcff373d210727"
+ },
+ "src": "17848:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4893,
+ "nodeType": "ExpressionStatement",
+ "src": "17848:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4898,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4894,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17913:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4896,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313134",
+ "id": 4895,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17926:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_114_by_1",
+ "typeString": "int_const 114"
+ },
+ "value": "114"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17913:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783263353634633430343666363465646261363838336361303662626334353335",
+ "id": 4897,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17933:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_58934115900064290859232836743818134837_by_1",
+ "typeString": "int_const 5893...(30 digits omitted)...4837"
+ },
+ "value": "0x2c564c4046f64edba6883ca06bbc4535"
+ },
+ "src": "17913:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4899,
+ "nodeType": "ExpressionStatement",
+ "src": "17913:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4904,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4900,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17978:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4902,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313135",
+ "id": 4901,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17991:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_115_by_1",
+ "typeString": "int_const 115"
+ },
+ "value": "115"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17978:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783263323937306334333166393532363431653035636234393365323365656433",
+ "id": 4903,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17998:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_58701203159797865214654223853927263955_by_1",
+ "typeString": "int_const 5870...(30 digits omitted)...3955"
+ },
+ "value": "0x2c2970c431f952641e05cb493e23eed3"
+ },
+ "src": "17978:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4905,
+ "nodeType": "ExpressionStatement",
+ "src": "17978:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4910,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4906,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18043:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4908,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313136",
+ "id": 4907,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18056:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_116_by_1",
+ "typeString": "int_const 116"
+ },
+ "value": "116"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18043:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783262666430353630636439656231343536336263376330373332383536633138",
+ "id": 4909,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18063:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_58470564005548587984364862866899430424_by_1",
+ "typeString": "int_const 5847...(30 digits omitted)...0424"
+ },
+ "value": "0x2bfd0560cd9eb14563bc7c0732856c18"
+ },
+ "src": "18043:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4911,
+ "nodeType": "ExpressionStatement",
+ "src": "18043:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4916,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4912,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18108:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4914,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313137",
+ "id": 4913,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18121:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_117_by_1",
+ "typeString": "int_const 117"
+ },
+ "value": "117"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18108:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783262643130383465643033333266376666343135306639643065663431613263",
+ "id": 4915,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18128:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_58242162365693428406397594903403305516_by_1",
+ "typeString": "int_const 5824...(30 digits omitted)...5516"
+ },
+ "value": "0x2bd1084ed0332f7ff4150f9d0ef41a2c"
+ },
+ "src": "18108:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4917,
+ "nodeType": "ExpressionStatement",
+ "src": "18108:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4922,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4918,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18173:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4920,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313138",
+ "id": 4919,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18186:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_118_by_1",
+ "typeString": "int_const 118"
+ },
+ "value": "118"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18173:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783262613537376430666131363238623736643034306231326138323439326662",
+ "id": 4921,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18193:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_58015962964008307710970589788915405563_by_1",
+ "typeString": "int_const 5801...(30 digits omitted)...5563"
+ },
+ "value": "0x2ba577d0fa1628b76d040b12a82492fb"
+ },
+ "src": "18173:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4923,
+ "nodeType": "ExpressionStatement",
+ "src": "18173:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4928,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4924,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18238:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4926,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313139",
+ "id": 4925,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18251:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_119_by_1",
+ "typeString": "int_const 119"
+ },
+ "value": "119"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18238:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783262376135323333636432313538316538353565383964633266316538613932",
+ "id": 4927,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18258:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_57791931297201156866686511914608921234_by_1",
+ "typeString": "int_const 5779...(30 digits omitted)...1234"
+ },
+ "value": "0x2b7a5233cd21581e855e89dc2f1e8a92"
+ },
+ "src": "18238:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4929,
+ "nodeType": "ExpressionStatement",
+ "src": "18238:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4934,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4930,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18303:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4932,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313230",
+ "id": 4931,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18316:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_120_by_1",
+ "typeString": "int_const 120"
+ },
+ "value": "120"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18303:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783262346639356364343639303464303564373262646364653333376439636337",
+ "id": 4933,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18323:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_57570033613218293176076279351194000583_by_1",
+ "typeString": "int_const 5757...(30 digits omitted)...0583"
+ },
+ "value": "0x2b4f95cd46904d05d72bdcde337d9cc7"
+ },
+ "src": "18303:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4935,
+ "nodeType": "ExpressionStatement",
+ "src": "18303:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4940,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4936,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18368:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4938,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313231",
+ "id": 4937,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18381:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_121_by_1",
+ "typeString": "int_const 121"
+ },
+ "value": "121"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18368:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783262323534306663396234643961626261336661636136363931393134363735",
+ "id": 4939,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18388:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_57350236890292752974853833075473860213_by_1",
+ "typeString": "int_const 5735...(30 digits omitted)...0213"
+ },
+ "value": "0x2b2540fc9b4d9abba3faca6691914675"
+ },
+ "src": "18368:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4941,
+ "nodeType": "ExpressionStatement",
+ "src": "18368:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4946,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4942,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18433:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4944,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313232",
+ "id": 4943,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18446:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_122_by_1",
+ "typeString": "int_const 122"
+ },
+ "value": "122"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18433:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783261666235323239663638643038333064386265386164623061306462373066",
+ "id": 4945,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18453:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_57132508816704680555143857466604631823_by_1",
+ "typeString": "int_const 5713...(30 digits omitted)...1823"
+ },
+ "value": "0x2afb5229f68d0830d8be8adb0a0db70f"
+ },
+ "src": "18433:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4947,
+ "nodeType": "ExpressionStatement",
+ "src": "18433:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4952,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4948,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18498:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4950,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313233",
+ "id": 4949,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18511:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_123_by_1",
+ "typeString": "int_const 123"
+ },
+ "value": "123"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18498:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783261643163376336336139623239346335626337336133626133616237613262",
+ "id": 4951,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18518:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_56916817771225259240345926660426267179_by_1",
+ "typeString": "int_const 5691...(30 digits omitted)...7179"
+ },
+ "value": "0x2ad1c7c63a9b294c5bc73a3ba3ab7a2b"
+ },
+ "src": "18498:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4953,
+ "nodeType": "ExpressionStatement",
+ "src": "18498:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4958,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4954,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18563:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4956,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313234",
+ "id": 4955,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18576:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_124_by_1",
+ "typeString": "int_const 124"
+ },
+ "value": "124"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18563:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783261613861303461633363626531656531633963383633363134363564626238",
+ "id": 4957,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18583:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_56703132804216983807771297030642981816_by_1",
+ "typeString": "int_const 5670...(30 digits omitted)...1816"
+ },
+ "value": "0x2aa8a04ac3cbe1ee1c9c86361465dbb8"
+ },
+ "src": "18563:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4959,
+ "nodeType": "ExpressionStatement",
+ "src": "18563:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4964,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4960,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18628:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4962,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313235",
+ "id": 4961,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18641:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_125_by_1",
+ "typeString": "int_const 125"
+ },
+ "value": "125"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18628:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783261376664613339326437323561343461326338616562396162333534333064",
+ "id": 4963,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18648:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_56491423619364318412491401339172373261_by_1",
+ "typeString": "int_const 5649...(30 digits omitted)...3261"
+ },
+ "value": "0x2a7fda392d725a44a2c8aeb9ab35430d"
+ },
+ "src": "18628:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4965,
+ "nodeType": "ExpressionStatement",
+ "src": "18628:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4970,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4966,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18693:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4968,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313236",
+ "id": 4967,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18706:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_126_by_1",
+ "typeString": "int_const 126"
+ },
+ "value": "126"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18693:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783261353737343162313863646536313837313737393262346661613231366462",
+ "id": 4969,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18713:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_56281660556009964768470705991401477851_by_1",
+ "typeString": "int_const 5628...(30 digits omitted)...7851"
+ },
+ "value": "0x2a57741b18cde618717792b4faa216db"
+ },
+ "src": "18693:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4971,
+ "nodeType": "ExpressionStatement",
+ "src": "18693:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4976,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4972,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18758:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4974,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313237",
+ "id": 4973,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18771:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_127_by_1",
+ "typeString": "int_const 127"
+ },
+ "value": "127"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18758:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783261326636633831663564383464643935306133353632366436643535303361",
+ "id": 4975,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18778:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_56073814572073085295245695095569469498_by_1",
+ "typeString": "int_const 5607...(30 digits omitted)...9498"
+ },
+ "value": "0x2a2f6c81f5d84dd950a35626d6d5503a"
+ },
+ "src": "18758:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4977,
+ "nodeType": "ExpressionStatement",
+ "src": "18758:54:7"
+ }
+ ]
+ },
+ "documentation": null,
+ "id": 4979,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "initLambertArray",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 4208,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "10481:2:7"
+ },
+ "returnParameters": {
+ "id": 4209,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "10492:0:7"
+ },
+ "scope": 8977,
+ "src": "10456:8364:7",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 4989,
+ "nodeType": "Block",
+ "src": "18952:65:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "id": 4983,
+ "name": "initMaxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4203,
+ "src": "18963:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$",
+ "typeString": "function ()"
+ }
+ },
+ "id": 4984,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18963:17:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 4985,
+ "nodeType": "ExpressionStatement",
+ "src": "18963:17:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "id": 4986,
+ "name": "initLambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4979,
+ "src": "18991:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$",
+ "typeString": "function ()"
+ }
+ },
+ "id": 4987,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18991:18:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 4988,
+ "nodeType": "ExpressionStatement",
+ "src": "18991:18:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 4980,
+ "nodeType": "StructuredDocumentation",
+ "src": "18828:95:7",
+ "text": " @dev should be executed after construction (too large for the constructor)"
+ },
+ "functionSelector": "e1c7392a",
+ "id": 4990,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "init",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 4981,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "18942:2:7"
+ },
+ "returnParameters": {
+ "id": 4982,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "18952:0:7"
+ },
+ "scope": 8977,
+ "src": "18929:88:7",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "baseFunctions": [
+ 13092
+ ],
+ "body": {
+ "id": 5084,
+ "nodeType": "Block",
+ "src": "19968:795:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5008,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5006,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4993,
+ "src": "20014:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5007,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20024:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "20014:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f535550504c59",
+ "id": 5009,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20027:20:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ },
+ "value": "ERR_INVALID_SUPPLY"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ }
+ ],
+ "id": 5005,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "20006:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5010,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20006:42:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5011,
+ "nodeType": "ExpressionStatement",
+ "src": "20006:42:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5015,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5013,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4995,
+ "src": "20067:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5014,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20085:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "20067:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f42414c414e4345",
+ "id": 5016,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20088:29:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ },
+ "value": "ERR_INVALID_RESERVE_BALANCE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ }
+ ],
+ "id": 5012,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "20059:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5017,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20059:59:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5018,
+ "nodeType": "ExpressionStatement",
+ "src": "20059:59:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5026,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5022,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5020,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4997,
+ "src": "20137:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5021,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20154:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "20137:18:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5025,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5023,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4997,
+ "src": "20159:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5024,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "20177:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "20159:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "20137:50:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f574549474854",
+ "id": 5027,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20189:28:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_e4e4c57eb13b428a7fc031dc1f6f2c3e13b61f7d7b93994b2d17f8dc75658178",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_WEIGHT\""
+ },
+ "value": "ERR_INVALID_RESERVE_WEIGHT"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_e4e4c57eb13b428a7fc031dc1f6f2c3e13b61f7d7b93994b2d17f8dc75658178",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_WEIGHT\""
+ }
+ ],
+ "id": 5019,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "20129:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5028,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20129:89:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5029,
+ "nodeType": "ExpressionStatement",
+ "src": "20129:89:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5032,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5030,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4999,
+ "src": "20281:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5031,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20292:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "20281:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5035,
+ "nodeType": "IfStatement",
+ "src": "20277:39:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5033,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20315:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "functionReturnParameters": 5004,
+ "id": 5034,
+ "nodeType": "Return",
+ "src": "20308:8:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5038,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5036,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4997,
+ "src": "20379:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5037,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "20397:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "20379:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5046,
+ "nodeType": "IfStatement",
+ "src": "20375:92:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5044,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5041,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4999,
+ "src": "20441:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5039,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4993,
+ "src": "20429:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5040,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "20429:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5042,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20429:20:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5043,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4995,
+ "src": "20452:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "20429:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5004,
+ "id": 5045,
+ "nodeType": "Return",
+ "src": "20422:45:7"
+ }
+ },
+ {
+ "assignments": [
+ 5048
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5048,
+ "mutability": "mutable",
+ "name": "result",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5084,
+ "src": "20480:14:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5047,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "20480:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5049,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "20480:14:7"
+ },
+ {
+ "assignments": [
+ 5051
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5051,
+ "mutability": "mutable",
+ "name": "precision",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5084,
+ "src": "20505:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5050,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "20505:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5052,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "20505:15:7"
+ },
+ {
+ "assignments": [
+ 5054
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5054,
+ "mutability": "mutable",
+ "name": "baseN",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5084,
+ "src": "20531:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5053,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "20531:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5059,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5057,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4995,
+ "src": "20559:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5055,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4999,
+ "src": "20547:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5056,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "add",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22271,
+ "src": "20547:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5058,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20547:28:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "20531:44:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5069,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 5060,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5048,
+ "src": "20587:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5061,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5051,
+ "src": "20595:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5062,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "20586:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5064,
+ "name": "baseN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5054,
+ "src": "20614:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5065,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4995,
+ "src": "20621:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5066,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4997,
+ "src": "20638:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5067,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "20654:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ ],
+ "id": 5063,
+ "name": "power",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5820,
+ "src": "20608:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint32_$returns$_t_uint256_$_t_uint8_$",
+ "typeString": "function (uint256,uint256,uint32,uint32) view returns (uint256,uint8)"
+ }
+ },
+ "id": 5068,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20608:57:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "src": "20586:79:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5070,
+ "nodeType": "ExpressionStatement",
+ "src": "20586:79:7"
+ },
+ {
+ "assignments": [
+ 5072
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5072,
+ "mutability": "mutable",
+ "name": "temp",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5084,
+ "src": "20676:12:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5071,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "20676:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5079,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5078,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5075,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5048,
+ "src": "20703:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5073,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4993,
+ "src": "20691:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5074,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "20691:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5076,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20691:19:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5077,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5051,
+ "src": "20714:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "20691:32:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "20676:47:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5082,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5080,
+ "name": "temp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5072,
+ "src": "20741:4:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5081,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4993,
+ "src": "20748:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "20741:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5004,
+ "id": 5083,
+ "nodeType": "Return",
+ "src": "20734:21:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 4991,
+ "nodeType": "StructuredDocumentation",
+ "src": "19025:641:7",
+ "text": " @dev given a token supply, reserve balance, weight and a deposit amount (in the reserve token),\n calculates the target amount for a given conversion (in the main token)\n Formula:\n return = _supply * ((1 + _amount / _reserveBalance) ^ (_reserveWeight / 1000000) - 1)\n @param _supply smart token supply\n @param _reserveBalance reserve balance\n @param _reserveWeight reserve weight, represented in ppm (1-1000000)\n @param _amount amount of reserve tokens to get the target amount for\n @return smart token amount"
+ },
+ "functionSelector": "f3250fe2",
+ "id": 5085,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "purchaseTargetAmount",
+ "nodeType": "FunctionDefinition",
+ "overrides": {
+ "id": 5001,
+ "nodeType": "OverrideSpecifier",
+ "overrides": [],
+ "src": "19936:8:7"
+ },
+ "parameters": {
+ "id": 5000,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 4993,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5085,
+ "src": "19702:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 4992,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "19702:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 4995,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5085,
+ "src": "19754:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 4994,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "19754:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 4997,
+ "mutability": "mutable",
+ "name": "_reserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5085,
+ "src": "19814:21:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 4996,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "19814:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 4999,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5085,
+ "src": "19872:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 4998,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "19872:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "19701:187:7"
+ },
+ "returnParameters": {
+ "id": 5004,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5003,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5085,
+ "src": "19954:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5002,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "19954:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "19953:9:7"
+ },
+ "scope": 8977,
+ "src": "19672:1091:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "baseFunctions": [
+ 13105
+ ],
+ "body": {
+ "id": 5198,
+ "nodeType": "Block",
+ "src": "21691:1021:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5103,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5101,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5088,
+ "src": "21737:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5102,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "21747:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "21737:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f535550504c59",
+ "id": 5104,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "21750:20:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ },
+ "value": "ERR_INVALID_SUPPLY"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ }
+ ],
+ "id": 5100,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "21729:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5105,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21729:42:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5106,
+ "nodeType": "ExpressionStatement",
+ "src": "21729:42:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5110,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5108,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5090,
+ "src": "21790:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5109,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "21808:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "21790:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f42414c414e4345",
+ "id": 5111,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "21811:29:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ },
+ "value": "ERR_INVALID_RESERVE_BALANCE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ }
+ ],
+ "id": 5107,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "21782:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5112,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21782:59:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5113,
+ "nodeType": "ExpressionStatement",
+ "src": "21782:59:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5121,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5117,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5115,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5092,
+ "src": "21860:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5116,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "21877:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "21860:18:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5120,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5118,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5092,
+ "src": "21882:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5119,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "21900:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "21882:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "21860:50:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f574549474854",
+ "id": 5122,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "21912:28:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_e4e4c57eb13b428a7fc031dc1f6f2c3e13b61f7d7b93994b2d17f8dc75658178",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_WEIGHT\""
+ },
+ "value": "ERR_INVALID_RESERVE_WEIGHT"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_e4e4c57eb13b428a7fc031dc1f6f2c3e13b61f7d7b93994b2d17f8dc75658178",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_WEIGHT\""
+ }
+ ],
+ "id": 5114,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "21852:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5123,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21852:89:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5124,
+ "nodeType": "ExpressionStatement",
+ "src": "21852:89:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5128,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5126,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5094,
+ "src": "21960:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5127,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5088,
+ "src": "21971:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "21960:18:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f414d4f554e54",
+ "id": 5129,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "21980:20:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_c44007bfe4e704be0ed1393660a827b4f88825f4b6fe1bc10cd38fc3fcb7d839",
+ "typeString": "literal_string \"ERR_INVALID_AMOUNT\""
+ },
+ "value": "ERR_INVALID_AMOUNT"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_c44007bfe4e704be0ed1393660a827b4f88825f4b6fe1bc10cd38fc3fcb7d839",
+ "typeString": "literal_string \"ERR_INVALID_AMOUNT\""
+ }
+ ],
+ "id": 5125,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "21952:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5130,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21952:49:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5131,
+ "nodeType": "ExpressionStatement",
+ "src": "21952:49:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5134,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5132,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5094,
+ "src": "22061:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5133,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "22072:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "22061:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5137,
+ "nodeType": "IfStatement",
+ "src": "22057:39:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5135,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "22095:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "functionReturnParameters": 5099,
+ "id": 5136,
+ "nodeType": "Return",
+ "src": "22088:8:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5140,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5138,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5094,
+ "src": "22168:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5139,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5088,
+ "src": "22179:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "22168:18:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5143,
+ "nodeType": "IfStatement",
+ "src": "22164:59:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5141,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5090,
+ "src": "22208:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5099,
+ "id": 5142,
+ "nodeType": "Return",
+ "src": "22201:22:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5146,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5144,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5092,
+ "src": "22286:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5145,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "22304:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "22286:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5154,
+ "nodeType": "IfStatement",
+ "src": "22282:92:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5152,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5149,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5094,
+ "src": "22356:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5147,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5090,
+ "src": "22336:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5148,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "22336:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5150,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "22336:28:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5151,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5088,
+ "src": "22367:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "22336:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5099,
+ "id": 5153,
+ "nodeType": "Return",
+ "src": "22329:45:7"
+ }
+ },
+ {
+ "assignments": [
+ 5156
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5156,
+ "mutability": "mutable",
+ "name": "result",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5198,
+ "src": "22387:14:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5155,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "22387:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5157,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "22387:14:7"
+ },
+ {
+ "assignments": [
+ 5159
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5159,
+ "mutability": "mutable",
+ "name": "precision",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5198,
+ "src": "22412:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5158,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "22412:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5160,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "22412:15:7"
+ },
+ {
+ "assignments": [
+ 5162
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5162,
+ "mutability": "mutable",
+ "name": "baseD",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5198,
+ "src": "22438:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5161,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "22438:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5166,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5165,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5163,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5088,
+ "src": "22454:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5164,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5094,
+ "src": "22464:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "22454:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "22438:33:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5176,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 5167,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5156,
+ "src": "22483:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5168,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5159,
+ "src": "22491:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5169,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "22482:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5171,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5088,
+ "src": "22510:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5172,
+ "name": "baseD",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5162,
+ "src": "22519:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5173,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "22526:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5174,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5092,
+ "src": "22538:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ ],
+ "id": 5170,
+ "name": "power",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5820,
+ "src": "22504:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint32_$returns$_t_uint256_$_t_uint8_$",
+ "typeString": "function (uint256,uint256,uint32,uint32) view returns (uint256,uint8)"
+ }
+ },
+ "id": 5175,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "22504:49:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "src": "22482:71:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5177,
+ "nodeType": "ExpressionStatement",
+ "src": "22482:71:7"
+ },
+ {
+ "assignments": [
+ 5179
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5179,
+ "mutability": "mutable",
+ "name": "temp1",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5198,
+ "src": "22564:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5178,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "22564:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5184,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5182,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5156,
+ "src": "22600:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5180,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5090,
+ "src": "22580:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5181,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "22580:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5183,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "22580:27:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "22564:43:7"
+ },
+ {
+ "assignments": [
+ 5186
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5186,
+ "mutability": "mutable",
+ "name": "temp2",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5198,
+ "src": "22618:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5185,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "22618:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5190,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5189,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5187,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5090,
+ "src": "22634:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5188,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5159,
+ "src": "22653:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "22634:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "22618:44:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5196,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5193,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5191,
+ "name": "temp1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5179,
+ "src": "22681:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5192,
+ "name": "temp2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5186,
+ "src": "22689:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "22681:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 5194,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "22680:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5195,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5156,
+ "src": "22698:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "22680:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5099,
+ "id": 5197,
+ "nodeType": "Return",
+ "src": "22673:31:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5086,
+ "nodeType": "StructuredDocumentation",
+ "src": "20771:638:7",
+ "text": " @dev given a token supply, reserve balance, weight and a sell amount (in the main token),\n calculates the target amount for a given conversion (in the reserve token)\n Formula:\n return = _reserveBalance * (1 - (1 - _amount / _supply) ^ (1000000 / _reserveWeight))\n @param _supply smart token supply\n @param _reserveBalance reserve balance\n @param _reserveWeight reserve weight, represented in ppm (1-1000000)\n @param _amount amount of smart tokens to get the target amount for\n @return reserve token amount"
+ },
+ "functionSelector": "76cf0b56",
+ "id": 5199,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "saleTargetAmount",
+ "nodeType": "FunctionDefinition",
+ "overrides": {
+ "id": 5096,
+ "nodeType": "OverrideSpecifier",
+ "overrides": [],
+ "src": "21659:8:7"
+ },
+ "parameters": {
+ "id": 5095,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5088,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5199,
+ "src": "21441:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5087,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "21441:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5090,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5199,
+ "src": "21489:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5089,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "21489:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5092,
+ "mutability": "mutable",
+ "name": "_reserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5199,
+ "src": "21545:21:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5091,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "21545:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5094,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5199,
+ "src": "21599:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5093,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "21599:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "21440:175:7"
+ },
+ "returnParameters": {
+ "id": 5099,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5098,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5199,
+ "src": "21677:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5097,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "21677:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "21676:9:7"
+ },
+ "scope": 8977,
+ "src": "21415:1297:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "baseFunctions": [
+ 13120
+ ],
+ "body": {
+ "id": 5304,
+ "nodeType": "Block",
+ "src": "23978:921:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5223,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5219,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5217,
+ "name": "_sourceReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5202,
+ "src": "24024:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5218,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24048:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "24024:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5222,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5220,
+ "name": "_targetReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5206,
+ "src": "24053:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5221,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24077:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "24053:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "24024:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f42414c414e4345",
+ "id": 5224,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24080:29:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ },
+ "value": "ERR_INVALID_RESERVE_BALANCE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ }
+ ],
+ "id": 5216,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "24016:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5225,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24016:94:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5226,
+ "nodeType": "ExpressionStatement",
+ "src": "24016:94:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5242,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5238,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5234,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5230,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5228,
+ "name": "_sourceReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5204,
+ "src": "24129:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5229,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24152:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "24129:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5233,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5231,
+ "name": "_sourceReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5204,
+ "src": "24157:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5232,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "24181:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "24157:34:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "24129:62:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5237,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5235,
+ "name": "_targetReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5208,
+ "src": "24212:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5236,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24235:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "24212:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "24129:107:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5241,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5239,
+ "name": "_targetReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5208,
+ "src": "24240:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5240,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "24264:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "24240:34:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "24129:145:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f574549474854",
+ "id": 5243,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24276:28:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_e4e4c57eb13b428a7fc031dc1f6f2c3e13b61f7d7b93994b2d17f8dc75658178",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_WEIGHT\""
+ },
+ "value": "ERR_INVALID_RESERVE_WEIGHT"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_e4e4c57eb13b428a7fc031dc1f6f2c3e13b61f7d7b93994b2d17f8dc75658178",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_WEIGHT\""
+ }
+ ],
+ "id": 5227,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "24121:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5244,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24121:184:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5245,
+ "nodeType": "ExpressionStatement",
+ "src": "24121:184:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5248,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5246,
+ "name": "_sourceReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5204,
+ "src": "24365:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5247,
+ "name": "_targetReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5208,
+ "src": "24389:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "24365:44:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5259,
+ "nodeType": "IfStatement",
+ "src": "24361:141:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5257,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5251,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5210,
+ "src": "24457:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5249,
+ "name": "_targetReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5206,
+ "src": "24431:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5250,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "24431:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5252,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24431:34:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5255,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5210,
+ "src": "24494:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5253,
+ "name": "_sourceReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5202,
+ "src": "24468:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5254,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "add",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22271,
+ "src": "24468:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5256,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24468:34:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "24431:71:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5215,
+ "id": 5258,
+ "nodeType": "Return",
+ "src": "24424:78:7"
+ }
+ },
+ {
+ "assignments": [
+ 5261
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5261,
+ "mutability": "mutable",
+ "name": "result",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5304,
+ "src": "24515:14:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5260,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "24515:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5262,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24515:14:7"
+ },
+ {
+ "assignments": [
+ 5264
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5264,
+ "mutability": "mutable",
+ "name": "precision",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5304,
+ "src": "24540:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5263,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "24540:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5265,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24540:15:7"
+ },
+ {
+ "assignments": [
+ 5267
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5267,
+ "mutability": "mutable",
+ "name": "baseN",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5304,
+ "src": "24566:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5266,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "24566:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5272,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5270,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5210,
+ "src": "24608:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5268,
+ "name": "_sourceReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5202,
+ "src": "24582:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5269,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "add",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22271,
+ "src": "24582:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5271,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24582:34:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24566:50:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5282,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 5273,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5261,
+ "src": "24628:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5274,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5264,
+ "src": "24636:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5275,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "24627:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5277,
+ "name": "baseN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5267,
+ "src": "24655:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5278,
+ "name": "_sourceReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5202,
+ "src": "24662:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5279,
+ "name": "_sourceReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5204,
+ "src": "24685:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5280,
+ "name": "_targetReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5208,
+ "src": "24707:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ ],
+ "id": 5276,
+ "name": "power",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5820,
+ "src": "24649:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint32_$returns$_t_uint256_$_t_uint8_$",
+ "typeString": "function (uint256,uint256,uint32,uint32) view returns (uint256,uint8)"
+ }
+ },
+ "id": 5281,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24649:79:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "src": "24627:101:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5283,
+ "nodeType": "ExpressionStatement",
+ "src": "24627:101:7"
+ },
+ {
+ "assignments": [
+ 5285
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5285,
+ "mutability": "mutable",
+ "name": "temp1",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5304,
+ "src": "24739:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5284,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "24739:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5290,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5288,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5261,
+ "src": "24781:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5286,
+ "name": "_targetReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5206,
+ "src": "24755:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5287,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "24755:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5289,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24755:33:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24739:49:7"
+ },
+ {
+ "assignments": [
+ 5292
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5292,
+ "mutability": "mutable",
+ "name": "temp2",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5304,
+ "src": "24799:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5291,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "24799:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5296,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5295,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5293,
+ "name": "_targetReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5206,
+ "src": "24815:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5294,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5264,
+ "src": "24840:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "24815:34:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24799:50:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5302,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5299,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5297,
+ "name": "temp1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5285,
+ "src": "24868:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5298,
+ "name": "temp2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5292,
+ "src": "24876:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "24868:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 5300,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "24867:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5301,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5261,
+ "src": "24885:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "24867:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5215,
+ "id": 5303,
+ "nodeType": "Return",
+ "src": "24860:31:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5200,
+ "nodeType": "StructuredDocumentation",
+ "src": "22720:842:7",
+ "text": " @dev given two reserve balances/weights and a sell amount (in the first reserve token),\n calculates the target amount for a conversion from the source reserve token to the target reserve token\n Formula:\n return = _targetReserveBalance * (1 - (_sourceReserveBalance / (_sourceReserveBalance + _amount)) ^ (_sourceReserveWeight / _targetReserveWeight))\n @param _sourceReserveBalance source reserve balance\n @param _sourceReserveWeight source reserve weight, represented in ppm (1-1000000)\n @param _targetReserveBalance target reserve balance\n @param _targetReserveWeight target reserve weight, represented in ppm (1-1000000)\n @param _amount source reserve amount\n @return target reserve amount"
+ },
+ "functionSelector": "94491fab",
+ "id": 5305,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "crossReserveTargetAmount",
+ "nodeType": "FunctionDefinition",
+ "overrides": {
+ "id": 5212,
+ "nodeType": "OverrideSpecifier",
+ "overrides": [],
+ "src": "23946:8:7"
+ },
+ "parameters": {
+ "id": 5211,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5202,
+ "mutability": "mutable",
+ "name": "_sourceReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5305,
+ "src": "23602:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5201,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "23602:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5204,
+ "mutability": "mutable",
+ "name": "_sourceReserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5305,
+ "src": "23672:27:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5203,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "23672:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5206,
+ "mutability": "mutable",
+ "name": "_targetReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5305,
+ "src": "23740:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5205,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "23740:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5208,
+ "mutability": "mutable",
+ "name": "_targetReserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5305,
+ "src": "23810:27:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5207,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "23810:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5210,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5305,
+ "src": "23878:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5209,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "23878:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "23601:293:7"
+ },
+ "returnParameters": {
+ "id": 5215,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5214,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5305,
+ "src": "23964:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5213,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "23964:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "23963:9:7"
+ },
+ "scope": 8977,
+ "src": "23568:1331:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "baseFunctions": [
+ 13133
+ ],
+ "body": {
+ "id": 5412,
+ "nodeType": "Block",
+ "src": "25813:815:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5323,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5321,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5308,
+ "src": "25859:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5322,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "25869:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "25859:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f535550504c59",
+ "id": 5324,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "25872:20:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ },
+ "value": "ERR_INVALID_SUPPLY"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ }
+ ],
+ "id": 5320,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "25851:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5325,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "25851:42:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5326,
+ "nodeType": "ExpressionStatement",
+ "src": "25851:42:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5330,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5328,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5310,
+ "src": "25912:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5329,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "25930:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "25912:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f42414c414e4345",
+ "id": 5331,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "25933:29:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ },
+ "value": "ERR_INVALID_RESERVE_BALANCE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ }
+ ],
+ "id": 5327,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "25904:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5332,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "25904:59:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5333,
+ "nodeType": "ExpressionStatement",
+ "src": "25904:59:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5343,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5337,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5335,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5312,
+ "src": "25982:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5336,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "25998:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "25982:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5342,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5338,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5312,
+ "src": "26003:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5341,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5339,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "26020:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 5340,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26033:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "26020:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "26003:31:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "25982:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f524154494f",
+ "id": 5344,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26036:27:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_8a8172d57fd89f78d9ce572e7618cbce6e9962212a6741dcc1911f87bc706d73",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_RATIO\""
+ },
+ "value": "ERR_INVALID_RESERVE_RATIO"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_8a8172d57fd89f78d9ce572e7618cbce6e9962212a6741dcc1911f87bc706d73",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_RATIO\""
+ }
+ ],
+ "id": 5334,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "25974:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5345,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "25974:90:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5346,
+ "nodeType": "ExpressionStatement",
+ "src": "25974:90:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5349,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5347,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5314,
+ "src": "26119:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5348,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26130:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "26119:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5352,
+ "nodeType": "IfStatement",
+ "src": "26115:39:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5350,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26153:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "functionReturnParameters": 5319,
+ "id": 5351,
+ "nodeType": "Return",
+ "src": "26146:8:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5355,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5353,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5312,
+ "src": "26224:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5354,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "26241:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "26224:27:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5368,
+ "nodeType": "IfStatement",
+ "src": "26220:101:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5366,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5364,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5361,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5358,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5310,
+ "src": "26286:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5356,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5314,
+ "src": "26274:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5357,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "26274:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5359,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "26274:28:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5360,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26305:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "26274:32:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 5362,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "26273:34:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5363,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5308,
+ "src": "26310:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "26273:44:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5365,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26320:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "26273:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5319,
+ "id": 5367,
+ "nodeType": "Return",
+ "src": "26266:55:7"
+ }
+ },
+ {
+ "assignments": [
+ 5370
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5370,
+ "mutability": "mutable",
+ "name": "result",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5412,
+ "src": "26334:14:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5369,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "26334:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5371,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "26334:14:7"
+ },
+ {
+ "assignments": [
+ 5373
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5373,
+ "mutability": "mutable",
+ "name": "precision",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5412,
+ "src": "26359:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5372,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "26359:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5374,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "26359:15:7"
+ },
+ {
+ "assignments": [
+ 5376
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5376,
+ "mutability": "mutable",
+ "name": "baseN",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5412,
+ "src": "26385:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5375,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "26385:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5381,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5379,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5314,
+ "src": "26413:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5377,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5308,
+ "src": "26401:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5378,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "add",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22271,
+ "src": "26401:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5380,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "26401:20:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "26385:36:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5391,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 5382,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5370,
+ "src": "26433:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5383,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5373,
+ "src": "26441:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5384,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "26432:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5386,
+ "name": "baseN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5376,
+ "src": "26460:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5387,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5308,
+ "src": "26467:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5388,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "26476:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5389,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5312,
+ "src": "26488:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ ],
+ "id": 5385,
+ "name": "power",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5820,
+ "src": "26454:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint32_$returns$_t_uint256_$_t_uint8_$",
+ "typeString": "function (uint256,uint256,uint32,uint32) view returns (uint256,uint8)"
+ }
+ },
+ "id": 5390,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "26454:48:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "src": "26432:70:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5392,
+ "nodeType": "ExpressionStatement",
+ "src": "26432:70:7"
+ },
+ {
+ "assignments": [
+ 5394
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5394,
+ "mutability": "mutable",
+ "name": "temp",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5412,
+ "src": "26513:12:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5393,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "26513:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5407,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5406,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5403,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5400,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5397,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5370,
+ "src": "26550:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5395,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5310,
+ "src": "26530:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5396,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "26530:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5398,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "26530:27:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5399,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26560:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "26530:31:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 5401,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "26529:33:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5402,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5373,
+ "src": "26566:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "26529:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 5404,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "26528:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5405,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26579:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "26528:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "26513:67:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5410,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5408,
+ "name": "temp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5394,
+ "src": "26598:4:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5409,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5310,
+ "src": "26605:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "26598:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5319,
+ "id": 5411,
+ "nodeType": "Return",
+ "src": "26591:29:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5306,
+ "nodeType": "StructuredDocumentation",
+ "src": "24907:665:7",
+ "text": " @dev given a smart token supply, reserve balance, reserve ratio and an amount of requested smart tokens,\n calculates the amount of reserve tokens required for purchasing the given amount of smart tokens\n Formula:\n return = _reserveBalance * (((_supply + _amount) / _supply) ^ (MAX_WEIGHT / _reserveRatio) - 1)\n @param _supply smart token supply\n @param _reserveBalance reserve balance\n @param _reserveRatio reserve ratio, represented in ppm (2-2000000)\n @param _amount requested amount of smart tokens\n @return reserve token amount"
+ },
+ "functionSelector": "ebbb2158",
+ "id": 5413,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "fundCost",
+ "nodeType": "FunctionDefinition",
+ "overrides": {
+ "id": 5316,
+ "nodeType": "OverrideSpecifier",
+ "overrides": [],
+ "src": "25781:8:7"
+ },
+ "parameters": {
+ "id": 5315,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5308,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5413,
+ "src": "25596:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5307,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "25596:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5310,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5413,
+ "src": "25636:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5309,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "25636:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5312,
+ "mutability": "mutable",
+ "name": "_reserveRatio",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5413,
+ "src": "25684:20:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5311,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "25684:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5314,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5413,
+ "src": "25729:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5313,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "25729:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "25595:150:7"
+ },
+ "returnParameters": {
+ "id": 5319,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5318,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5413,
+ "src": "25799:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5317,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "25799:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "25798:9:7"
+ },
+ "scope": 8977,
+ "src": "25578:1050:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "baseFunctions": [
+ 13146
+ ],
+ "body": {
+ "id": 5509,
+ "nodeType": "Block",
+ "src": "27587:793:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5431,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5429,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5416,
+ "src": "27633:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5430,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27643:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "27633:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f535550504c59",
+ "id": 5432,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27646:20:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ },
+ "value": "ERR_INVALID_SUPPLY"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ }
+ ],
+ "id": 5428,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "27625:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5433,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "27625:42:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5434,
+ "nodeType": "ExpressionStatement",
+ "src": "27625:42:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5438,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5436,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5418,
+ "src": "27686:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5437,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27704:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "27686:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f42414c414e4345",
+ "id": 5439,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27707:29:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ },
+ "value": "ERR_INVALID_RESERVE_BALANCE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ }
+ ],
+ "id": 5435,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "27678:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5440,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "27678:59:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5441,
+ "nodeType": "ExpressionStatement",
+ "src": "27678:59:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5451,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5445,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5443,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5420,
+ "src": "27756:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5444,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27772:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "27756:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5450,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5446,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5420,
+ "src": "27777:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5449,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5447,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "27794:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 5448,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27807:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "27794:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "27777:31:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "27756:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f524154494f",
+ "id": 5452,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27810:27:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_8a8172d57fd89f78d9ce572e7618cbce6e9962212a6741dcc1911f87bc706d73",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_RATIO\""
+ },
+ "value": "ERR_INVALID_RESERVE_RATIO"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_8a8172d57fd89f78d9ce572e7618cbce6e9962212a6741dcc1911f87bc706d73",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_RATIO\""
+ }
+ ],
+ "id": 5442,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "27748:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5453,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "27748:90:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5454,
+ "nodeType": "ExpressionStatement",
+ "src": "27748:90:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5457,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5455,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5422,
+ "src": "27893:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5456,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27904:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "27893:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5460,
+ "nodeType": "IfStatement",
+ "src": "27889:39:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5458,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27927:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "functionReturnParameters": 5427,
+ "id": 5459,
+ "nodeType": "Return",
+ "src": "27920:8:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5463,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5461,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5420,
+ "src": "27998:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5462,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "28015:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "27998:27:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5471,
+ "nodeType": "IfStatement",
+ "src": "27994:91:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5469,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5466,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5416,
+ "src": "28059:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5464,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5422,
+ "src": "28047:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5465,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "28047:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5467,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28047:20:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5468,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5418,
+ "src": "28070:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "28047:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5427,
+ "id": 5470,
+ "nodeType": "Return",
+ "src": "28040:45:7"
+ }
+ },
+ {
+ "assignments": [
+ 5473
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5473,
+ "mutability": "mutable",
+ "name": "result",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5509,
+ "src": "28098:14:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5472,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "28098:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5474,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "28098:14:7"
+ },
+ {
+ "assignments": [
+ 5476
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5476,
+ "mutability": "mutable",
+ "name": "precision",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5509,
+ "src": "28123:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5475,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "28123:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5477,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "28123:15:7"
+ },
+ {
+ "assignments": [
+ 5479
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5479,
+ "mutability": "mutable",
+ "name": "baseN",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5509,
+ "src": "28149:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5478,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "28149:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5484,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5482,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5422,
+ "src": "28185:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5480,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5418,
+ "src": "28165:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5481,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "add",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22271,
+ "src": "28165:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5483,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28165:28:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "28149:44:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5494,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 5485,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5473,
+ "src": "28205:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5486,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5476,
+ "src": "28213:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5487,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "28204:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5489,
+ "name": "baseN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5479,
+ "src": "28232:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5490,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5418,
+ "src": "28239:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5491,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5420,
+ "src": "28256:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5492,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "28271:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ ],
+ "id": 5488,
+ "name": "power",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5820,
+ "src": "28226:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint32_$returns$_t_uint256_$_t_uint8_$",
+ "typeString": "function (uint256,uint256,uint32,uint32) view returns (uint256,uint8)"
+ }
+ },
+ "id": 5493,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28226:56:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "src": "28204:78:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5495,
+ "nodeType": "ExpressionStatement",
+ "src": "28204:78:7"
+ },
+ {
+ "assignments": [
+ 5497
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5497,
+ "mutability": "mutable",
+ "name": "temp",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5509,
+ "src": "28293:12:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5496,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "28293:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5504,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5503,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5500,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5473,
+ "src": "28320:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5498,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5416,
+ "src": "28308:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5499,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "28308:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5501,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28308:19:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5502,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5476,
+ "src": "28331:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "28308:32:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "28293:47:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5507,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5505,
+ "name": "temp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5497,
+ "src": "28358:4:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5506,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5416,
+ "src": "28365:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "28358:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5427,
+ "id": 5508,
+ "nodeType": "Return",
+ "src": "28351:21:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5414,
+ "nodeType": "StructuredDocumentation",
+ "src": "26636:670:7",
+ "text": " @dev given a smart token supply, reserve balance, reserve ratio and an amount of reserve tokens to fund with,\n calculates the amount of smart tokens received for purchasing with the given amount of reserve tokens\n Formula:\n return = _supply * ((_amount / _reserveBalance + 1) ^ (_reserveRatio / MAX_WEIGHT) - 1)\n @param _supply smart token supply\n @param _reserveBalance reserve balance\n @param _reserveRatio reserve ratio, represented in ppm (2-2000000)\n @param _amount amount of reserve tokens to fund with\n @return smart token amount"
+ },
+ "functionSelector": "2f55bdb5",
+ "id": 5510,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "fundSupplyAmount",
+ "nodeType": "FunctionDefinition",
+ "overrides": {
+ "id": 5424,
+ "nodeType": "OverrideSpecifier",
+ "overrides": [],
+ "src": "27555:8:7"
+ },
+ "parameters": {
+ "id": 5423,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5416,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5510,
+ "src": "27338:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5415,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "27338:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5418,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5510,
+ "src": "27386:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5417,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "27386:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5420,
+ "mutability": "mutable",
+ "name": "_reserveRatio",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5510,
+ "src": "27442:20:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5419,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "27442:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5422,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5510,
+ "src": "27495:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5421,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "27495:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "27337:174:7"
+ },
+ "returnParameters": {
+ "id": 5427,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5426,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5510,
+ "src": "27573:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5425,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "27573:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "27572:9:7"
+ },
+ "scope": 8977,
+ "src": "27312:1068:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "baseFunctions": [
+ 13159
+ ],
+ "body": {
+ "id": 5625,
+ "nodeType": "Block",
+ "src": "29367:1026:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5528,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5526,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5513,
+ "src": "29413:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5527,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29423:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "29413:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f535550504c59",
+ "id": 5529,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29426:20:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ },
+ "value": "ERR_INVALID_SUPPLY"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ }
+ ],
+ "id": 5525,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "29405:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5530,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29405:42:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5531,
+ "nodeType": "ExpressionStatement",
+ "src": "29405:42:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5535,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5533,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5515,
+ "src": "29466:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5534,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29484:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "29466:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f42414c414e4345",
+ "id": 5536,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29487:29:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ },
+ "value": "ERR_INVALID_RESERVE_BALANCE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ }
+ ],
+ "id": 5532,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "29458:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5537,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29458:59:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5538,
+ "nodeType": "ExpressionStatement",
+ "src": "29458:59:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5548,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5542,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5540,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5517,
+ "src": "29536:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5541,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29552:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "29536:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5547,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5543,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5517,
+ "src": "29557:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5546,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5544,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "29574:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 5545,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29587:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "29574:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "29557:31:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "29536:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f524154494f",
+ "id": 5549,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29590:27:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_8a8172d57fd89f78d9ce572e7618cbce6e9962212a6741dcc1911f87bc706d73",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_RATIO\""
+ },
+ "value": "ERR_INVALID_RESERVE_RATIO"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_8a8172d57fd89f78d9ce572e7618cbce6e9962212a6741dcc1911f87bc706d73",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_RATIO\""
+ }
+ ],
+ "id": 5539,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "29528:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5550,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29528:90:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5551,
+ "nodeType": "ExpressionStatement",
+ "src": "29528:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5555,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5553,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5519,
+ "src": "29637:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5554,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5513,
+ "src": "29648:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "29637:18:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f414d4f554e54",
+ "id": 5556,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29657:20:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_c44007bfe4e704be0ed1393660a827b4f88825f4b6fe1bc10cd38fc3fcb7d839",
+ "typeString": "literal_string \"ERR_INVALID_AMOUNT\""
+ },
+ "value": "ERR_INVALID_AMOUNT"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_c44007bfe4e704be0ed1393660a827b4f88825f4b6fe1bc10cd38fc3fcb7d839",
+ "typeString": "literal_string \"ERR_INVALID_AMOUNT\""
+ }
+ ],
+ "id": 5552,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "29629:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5557,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29629:49:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5558,
+ "nodeType": "ExpressionStatement",
+ "src": "29629:49:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5561,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5559,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5519,
+ "src": "29733:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5560,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29744:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "29733:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5564,
+ "nodeType": "IfStatement",
+ "src": "29729:39:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5562,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29767:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "functionReturnParameters": 5524,
+ "id": 5563,
+ "nodeType": "Return",
+ "src": "29760:8:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5567,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5565,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5519,
+ "src": "29844:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5566,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5513,
+ "src": "29855:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "29844:18:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5570,
+ "nodeType": "IfStatement",
+ "src": "29840:59:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5568,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5515,
+ "src": "29884:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5524,
+ "id": 5569,
+ "nodeType": "Return",
+ "src": "29877:22:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5573,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5571,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5517,
+ "src": "29969:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5572,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "29986:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "29969:27:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5581,
+ "nodeType": "IfStatement",
+ "src": "29965:91:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5579,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5576,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5515,
+ "src": "30030:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5574,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5519,
+ "src": "30018:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5575,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "30018:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5577,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30018:28:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5578,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5513,
+ "src": "30049:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "30018:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5524,
+ "id": 5580,
+ "nodeType": "Return",
+ "src": "30011:45:7"
+ }
+ },
+ {
+ "assignments": [
+ 5583
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5583,
+ "mutability": "mutable",
+ "name": "result",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5625,
+ "src": "30069:14:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5582,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30069:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5584,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "30069:14:7"
+ },
+ {
+ "assignments": [
+ 5586
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5586,
+ "mutability": "mutable",
+ "name": "precision",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5625,
+ "src": "30094:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5585,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "30094:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5587,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "30094:15:7"
+ },
+ {
+ "assignments": [
+ 5589
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5589,
+ "mutability": "mutable",
+ "name": "baseD",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5625,
+ "src": "30120:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5588,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30120:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5593,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5592,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5590,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5513,
+ "src": "30136:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5591,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5519,
+ "src": "30146:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "30136:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "30120:33:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5603,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 5594,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5583,
+ "src": "30165:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5595,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5586,
+ "src": "30173:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5596,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "30164:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5598,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5513,
+ "src": "30192:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5599,
+ "name": "baseD",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5589,
+ "src": "30201:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5600,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "30208:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5601,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5517,
+ "src": "30220:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ ],
+ "id": 5597,
+ "name": "power",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5820,
+ "src": "30186:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint32_$returns$_t_uint256_$_t_uint8_$",
+ "typeString": "function (uint256,uint256,uint32,uint32) view returns (uint256,uint8)"
+ }
+ },
+ "id": 5602,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30186:48:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "src": "30164:70:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5604,
+ "nodeType": "ExpressionStatement",
+ "src": "30164:70:7"
+ },
+ {
+ "assignments": [
+ 5606
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5606,
+ "mutability": "mutable",
+ "name": "temp1",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5625,
+ "src": "30245:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5605,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30245:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5611,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5609,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5583,
+ "src": "30281:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5607,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5515,
+ "src": "30261:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5608,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "30261:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5610,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30261:27:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "30245:43:7"
+ },
+ {
+ "assignments": [
+ 5613
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5613,
+ "mutability": "mutable",
+ "name": "temp2",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5625,
+ "src": "30299:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5612,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30299:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5617,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5616,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5614,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5515,
+ "src": "30315:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5615,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5586,
+ "src": "30334:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "30315:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "30299:44:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5623,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5620,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5618,
+ "name": "temp1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5606,
+ "src": "30362:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5619,
+ "name": "temp2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5613,
+ "src": "30370:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "30362:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 5621,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "30361:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5622,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5583,
+ "src": "30379:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "30361:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5524,
+ "id": 5624,
+ "nodeType": "Return",
+ "src": "30354:31:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5511,
+ "nodeType": "StructuredDocumentation",
+ "src": "28388:668:7",
+ "text": " @dev given a smart token supply, reserve balance, reserve ratio and an amount of smart tokens to liquidate,\n calculates the amount of reserve tokens received for selling the given amount of smart tokens\n Formula:\n return = _reserveBalance * (1 - ((_supply - _amount) / _supply) ^ (MAX_WEIGHT / _reserveRatio))\n @param _supply smart token supply\n @param _reserveBalance reserve balance\n @param _reserveRatio reserve ratio, represented in ppm (2-2000000)\n @param _amount amount of smart tokens to liquidate\n @return reserve token amount"
+ },
+ "functionSelector": "8074590a",
+ "id": 5626,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "liquidateReserveAmount",
+ "nodeType": "FunctionDefinition",
+ "overrides": {
+ "id": 5521,
+ "nodeType": "OverrideSpecifier",
+ "overrides": [],
+ "src": "29335:8:7"
+ },
+ "parameters": {
+ "id": 5520,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5513,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5626,
+ "src": "29094:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5512,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "29094:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5515,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5626,
+ "src": "29148:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5514,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "29148:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5517,
+ "mutability": "mutable",
+ "name": "_reserveRatio",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5626,
+ "src": "29210:20:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5516,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "29210:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5519,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5626,
+ "src": "29269:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5518,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "29269:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "29093:192:7"
+ },
+ "returnParameters": {
+ "id": 5524,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5523,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5626,
+ "src": "29353:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5522,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "29353:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "29352:9:7"
+ },
+ "scope": 8977,
+ "src": "29062:1331:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "baseFunctions": [
+ 13176
+ ],
+ "body": {
+ "id": 5729,
+ "nodeType": "Block",
+ "src": "33118:1031:7",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5647,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5645,
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5629,
+ "src": "33133:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5646,
+ "name": "_primaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5631,
+ "src": "33165:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "33133:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5670,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5666,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5662,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5660,
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5629,
+ "src": "33343:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5661,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33374:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "33343:32:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5665,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5663,
+ "name": "_primaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5631,
+ "src": "33379:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5664,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33404:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "33379:26:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "33343:62:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5669,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5667,
+ "name": "_secondaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5633,
+ "src": "33409:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5668,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33436:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "33409:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "33343:94:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f42414c414e4345",
+ "id": 5671,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33439:29:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ },
+ "value": "ERR_INVALID_RESERVE_BALANCE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ }
+ ],
+ "id": 5659,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "33335:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5672,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33335:134:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5673,
+ "nodeType": "ExpressionStatement",
+ "src": "33335:134:7"
+ },
+ "id": 5674,
+ "nodeType": "IfStatement",
+ "src": "33129:340:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5655,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5651,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5649,
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5629,
+ "src": "33210:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5650,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33241:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "33210:32:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "||",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5654,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5652,
+ "name": "_secondaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5633,
+ "src": "33246:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5653,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33273:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "33246:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "33210:64:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f42414c414e4345",
+ "id": 5656,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33276:29:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ },
+ "value": "ERR_INVALID_RESERVE_BALANCE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ }
+ ],
+ "id": 5648,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "33202:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5657,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33202:104:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5658,
+ "nodeType": "ExpressionStatement",
+ "src": "33202:104:7"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5682,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5678,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5676,
+ "name": "_reserveRateNumerator",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5635,
+ "src": "33488:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5677,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33512:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "33488:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5681,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5679,
+ "name": "_reserveRateDenominator",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5637,
+ "src": "33517:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5680,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33543:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "33517:27:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "33488:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f52415445",
+ "id": 5683,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33546:26:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_ef2ffbf1bb88550d8f6c1cbc448ef8c9b658c0125c3eaac6dd7d95fb505ee813",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_RATE\""
+ },
+ "value": "ERR_INVALID_RESERVE_RATE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_ef2ffbf1bb88550d8f6c1cbc448ef8c9b658c0125c3eaac6dd7d95fb505ee813",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_RATE\""
+ }
+ ],
+ "id": 5675,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "33480:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5684,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33480:93:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5685,
+ "nodeType": "ExpressionStatement",
+ "src": "33480:93:7"
+ },
+ {
+ "assignments": [
+ 5687
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5687,
+ "mutability": "mutable",
+ "name": "tq",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5729,
+ "src": "33586:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5686,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33586:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5692,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5690,
+ "name": "_reserveRateNumerator",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5635,
+ "src": "33632:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5688,
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5629,
+ "src": "33599:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5689,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "33599:32:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5691,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33599:55:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "33586:68:7"
+ },
+ {
+ "assignments": [
+ 5694
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5694,
+ "mutability": "mutable",
+ "name": "rp",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5729,
+ "src": "33665:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5693,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33665:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5699,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5697,
+ "name": "_reserveRateDenominator",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5637,
+ "src": "33707:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5695,
+ "name": "_secondaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5633,
+ "src": "33678:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5696,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "33678:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5698,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33678:53:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "33665:66:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5702,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5700,
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5629,
+ "src": "33748:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5701,
+ "name": "_primaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5631,
+ "src": "33779:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "33748:53:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5711,
+ "nodeType": "IfStatement",
+ "src": "33744:169:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5704,
+ "name": "_primaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5631,
+ "src": "33846:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5705,
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5629,
+ "src": "33870:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5706,
+ "name": "tq",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5687,
+ "src": "33900:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5707,
+ "name": "rp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5694,
+ "src": "33904:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "74727565",
+ "id": 5708,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33908:4:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "true"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ ],
+ "id": 5703,
+ "name": "balancedWeightsByStake",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8547,
+ "src": "33823:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$returns$_t_uint32_$_t_uint32_$",
+ "typeString": "function (uint256,uint256,uint256,uint256,bool) view returns (uint32,uint32)"
+ }
+ },
+ "id": 5709,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33823:90:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint32_$_t_uint32_$",
+ "typeString": "tuple(uint32,uint32)"
+ }
+ },
+ "functionReturnParameters": 5644,
+ "id": 5710,
+ "nodeType": "Return",
+ "src": "33816:97:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5714,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5712,
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5629,
+ "src": "33930:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5713,
+ "name": "_primaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5631,
+ "src": "33961:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "33930:53:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5723,
+ "nodeType": "IfStatement",
+ "src": "33926:170:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5716,
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5629,
+ "src": "34028:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5717,
+ "name": "_primaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5631,
+ "src": "34058:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5718,
+ "name": "tq",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5687,
+ "src": "34082:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5719,
+ "name": "rp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5694,
+ "src": "34086:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "66616c7365",
+ "id": 5720,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "34090:5:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "false"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ ],
+ "id": 5715,
+ "name": "balancedWeightsByStake",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8547,
+ "src": "34005:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$returns$_t_uint32_$_t_uint32_$",
+ "typeString": "function (uint256,uint256,uint256,uint256,bool) view returns (uint32,uint32)"
+ }
+ },
+ "id": 5721,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "34005:91:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint32_$_t_uint32_$",
+ "typeString": "tuple(uint32,uint32)"
+ }
+ },
+ "functionReturnParameters": 5644,
+ "id": 5722,
+ "nodeType": "Return",
+ "src": "33998:98:7"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5725,
+ "name": "tq",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5687,
+ "src": "34134:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5726,
+ "name": "rp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5694,
+ "src": "34138:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 5724,
+ "name": "normalizedWeights",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8656,
+ "src": "34116:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint32_$_t_uint32_$",
+ "typeString": "function (uint256,uint256) pure returns (uint32,uint32)"
+ }
+ },
+ "id": 5727,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "34116:25:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint32_$_t_uint32_$",
+ "typeString": "tuple(uint32,uint32)"
+ }
+ },
+ "functionReturnParameters": 5644,
+ "id": 5728,
+ "nodeType": "Return",
+ "src": "34109:32:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5627,
+ "nodeType": "StructuredDocumentation",
+ "src": "30401:2317:7",
+ "text": " @dev The arbitrage incentive is to convert to the point where the on-chain price is equal to the off-chain price.\n We want this operation to also impact the primary reserve balance becoming equal to the primary reserve staked balance.\n In other words, we want the arbitrager to convert the difference between the reserve balance and the reserve staked balance.\n Formula input:\n - let t denote the primary reserve token staked balance\n - let s denote the primary reserve token balance\n - let r denote the secondary reserve token balance\n - let q denote the numerator of the rate between the tokens\n - let p denote the denominator of the rate between the tokens\n Where p primary tokens are equal to q secondary tokens\n Formula output:\n - compute x = W(t / r * q / p * log(s / t)) / log(s / t)\n - return x / (1 + x) as the weight of the primary reserve token\n - return 1 / (1 + x) as the weight of the secondary reserve token\n Where W is the Lambert W Function\n If the rate-provider provides the rates for a common unit, for example:\n - P = 2 ==> 2 primary reserve tokens = 1 ether\n - Q = 3 ==> 3 secondary reserve tokens = 1 ether\n Then you can simply use p = P and q = Q\n If the rate-provider provides the rates for a single unit, for example:\n - P = 2 ==> 1 primary reserve token = 2 ethers\n - Q = 3 ==> 1 secondary reserve token = 3 ethers\n Then you can simply use p = Q and q = P\n @param _primaryReserveStakedBalance the primary reserve token staked balance\n @param _primaryReserveBalance the primary reserve token balance\n @param _secondaryReserveBalance the secondary reserve token balance\n @param _reserveRateNumerator the numerator of the rate between the tokens\n @param _reserveRateDenominator the denominator of the rate between the tokens\n Note that `numerator / denominator` should represent the amount of secondary tokens equal to one primary token\n @return the weight of the primary reserve token and the weight of the secondary reserve token, both in ppm (0-1000000)"
+ },
+ "functionSelector": "a11aa1b4",
+ "id": 5730,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "balancedWeights",
+ "nodeType": "FunctionDefinition",
+ "overrides": {
+ "id": 5639,
+ "nodeType": "OverrideSpecifier",
+ "overrides": [],
+ "src": "33079:8:7"
+ },
+ "parameters": {
+ "id": 5638,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5629,
+ "mutability": "mutable",
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5730,
+ "src": "32749:36:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5628,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32749:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5631,
+ "mutability": "mutable",
+ "name": "_primaryReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5730,
+ "src": "32817:30:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5630,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32817:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5633,
+ "mutability": "mutable",
+ "name": "_secondaryReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5730,
+ "src": "32879:32:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5632,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32879:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5635,
+ "mutability": "mutable",
+ "name": "_reserveRateNumerator",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5730,
+ "src": "32943:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5634,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32943:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5637,
+ "mutability": "mutable",
+ "name": "_reserveRateDenominator",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5730,
+ "src": "33004:31:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5636,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33004:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "32748:288:7"
+ },
+ "returnParameters": {
+ "id": 5644,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5641,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5730,
+ "src": "33097:6:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5640,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "33097:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5643,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5730,
+ "src": "33105:6:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5642,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "33105:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "33096:16:7"
+ },
+ "scope": 8977,
+ "src": "32724:1425:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 5819,
+ "nodeType": "Block",
+ "src": "35853:677:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5749,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5747,
+ "name": "_baseN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5733,
+ "src": "35872:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5748,
+ "name": "MAX_NUM",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3592,
+ "src": "35881:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "35872:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ ],
+ "id": 5746,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "35864:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
+ "typeString": "function (bool) pure"
+ }
+ },
+ "id": 5750,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "35864:25:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5751,
+ "nodeType": "ExpressionStatement",
+ "src": "35864:25:7"
+ },
+ {
+ "assignments": [
+ 5753
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5753,
+ "mutability": "mutable",
+ "name": "baseLog",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5819,
+ "src": "35902:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5752,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "35902:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5754,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "35902:15:7"
+ },
+ {
+ "assignments": [
+ 5756
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5756,
+ "mutability": "mutable",
+ "name": "base",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5819,
+ "src": "35928:12:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5755,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "35928:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5762,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5761,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5759,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5757,
+ "name": "_baseN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5733,
+ "src": "35943:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5758,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "35952:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "35943:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5760,
+ "name": "_baseD",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5735,
+ "src": "35962:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "35943:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "35928:40:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5765,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5763,
+ "name": "base",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5756,
+ "src": "35983:4:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5764,
+ "name": "OPT_LOG_MAX_VAL",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3601,
+ "src": "35990:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "35983:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "id": 5779,
+ "nodeType": "Block",
+ "src": "36075:53:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5777,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5773,
+ "name": "baseLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5753,
+ "src": "36090:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5775,
+ "name": "base",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5756,
+ "src": "36111:4:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 5774,
+ "name": "generalLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5906,
+ "src": "36100:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5776,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "36100:16:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "36090:26:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5778,
+ "nodeType": "ExpressionStatement",
+ "src": "36090:26:7"
+ }
+ ]
+ },
+ "id": 5780,
+ "nodeType": "IfStatement",
+ "src": "35979:149:7",
+ "trueBody": {
+ "id": 5772,
+ "nodeType": "Block",
+ "src": "36007:53:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5770,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5766,
+ "name": "baseLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5753,
+ "src": "36022:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5768,
+ "name": "base",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5756,
+ "src": "36043:4:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 5767,
+ "name": "optimalLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6866,
+ "src": "36032:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5769,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "36032:16:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "36022:26:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5771,
+ "nodeType": "ExpressionStatement",
+ "src": "36022:26:7"
+ }
+ ]
+ }
+ },
+ {
+ "assignments": [
+ 5782
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5782,
+ "mutability": "mutable",
+ "name": "baseLogTimesExp",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5819,
+ "src": "36140:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5781,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "36140:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5788,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5787,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5785,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5783,
+ "name": "baseLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5753,
+ "src": "36166:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5784,
+ "name": "_expN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5737,
+ "src": "36176:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "36166:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5786,
+ "name": "_expD",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5739,
+ "src": "36184:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "36166:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "36140:49:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5791,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5789,
+ "name": "baseLogTimesExp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5782,
+ "src": "36204:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5790,
+ "name": "OPT_EXP_MAX_VAL",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3604,
+ "src": "36222:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "36204:33:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "id": 5817,
+ "nodeType": "Block",
+ "src": "36332:191:7",
+ "statements": [
+ {
+ "assignments": [
+ 5800
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5800,
+ "mutability": "mutable",
+ "name": "precision",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5817,
+ "src": "36347:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5799,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "36347:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5804,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5802,
+ "name": "baseLogTimesExp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5782,
+ "src": "36391:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 5801,
+ "name": "findPositionInMaxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6036,
+ "src": "36365:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint8_$",
+ "typeString": "function (uint256) view returns (uint8)"
+ }
+ },
+ "id": 5803,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "36365:42:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "36347:60:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5811,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5806,
+ "name": "baseLogTimesExp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5782,
+ "src": "36441:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "id": 5809,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5807,
+ "name": "MAX_PRECISION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3583,
+ "src": "36461:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5808,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5800,
+ "src": "36477:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "36461:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5810,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "36460:27:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "36441:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5812,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5800,
+ "src": "36489:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ ],
+ "id": 5805,
+ "name": "generalExp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6546,
+ "src": "36430:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint8_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint8) pure returns (uint256)"
+ }
+ },
+ "id": 5813,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "36430:69:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5814,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5800,
+ "src": "36501:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5815,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "36429:82:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "functionReturnParameters": 5745,
+ "id": 5816,
+ "nodeType": "Return",
+ "src": "36422:89:7"
+ }
+ ]
+ },
+ "id": 5818,
+ "nodeType": "IfStatement",
+ "src": "36200:323:7",
+ "trueBody": {
+ "id": 5798,
+ "nodeType": "Block",
+ "src": "36239:78:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5793,
+ "name": "baseLogTimesExp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5782,
+ "src": "36273:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 5792,
+ "name": "optimalExp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7276,
+ "src": "36262:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5794,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "36262:27:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5795,
+ "name": "MAX_PRECISION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3583,
+ "src": "36291:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5796,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "36261:44:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "functionReturnParameters": 5745,
+ "id": 5797,
+ "nodeType": "Return",
+ "src": "36254:51:7"
+ }
+ ]
+ }
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5731,
+ "nodeType": "StructuredDocumentation",
+ "src": "34157:1576:7",
+ "text": " @dev General Description:\n Determine a value of precision.\n Calculate an integer approximation of (_baseN / _baseD) ^ (_expN / _expD) * 2 ^ precision.\n Return the result along with the precision used.\n Detailed Description:\n Instead of calculating \"base ^ exp\", we calculate \"e ^ (log(base) * exp)\".\n The value of \"log(base)\" is represented with an integer slightly smaller than \"log(base) * 2 ^ precision\".\n The larger \"precision\" is, the more accurately this value represents the real value.\n However, the larger \"precision\" is, the more bits are required in order to store this value.\n And the exponentiation function, which takes \"x\" and calculates \"e ^ x\", is limited to a maximum exponent (maximum value of \"x\").\n This maximum exponent depends on the \"precision\" used, and it is given by \"maxExpArray[precision] >> (MAX_PRECISION - precision)\".\n Hence we need to determine the highest precision which can be used for the given input, before calling the exponentiation function.\n This allows us to compute \"base ^ exp\" with maximum accuracy and without exceeding 256 bits in any of the intermediate computations.\n This functions assumes that \"_expN < 2 ^ 256 / log(MAX_NUM - 1)\", otherwise the multiplication should be replaced with a \"safeMul\".\n Since we rely on unsigned-integer arithmetic and \"base < 1\" ==> \"log(base) < 0\", this function does not support \"_baseN < _baseD\"."
+ },
+ "id": 5820,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "power",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 5740,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5733,
+ "mutability": "mutable",
+ "name": "_baseN",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5820,
+ "src": "35754:14:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5732,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "35754:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5735,
+ "mutability": "mutable",
+ "name": "_baseD",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5820,
+ "src": "35770:14:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5734,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "35770:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5737,
+ "mutability": "mutable",
+ "name": "_expN",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5820,
+ "src": "35786:12:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5736,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "35786:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5739,
+ "mutability": "mutable",
+ "name": "_expD",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5820,
+ "src": "35800:12:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5738,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "35800:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "35753:60:7"
+ },
+ "returnParameters": {
+ "id": 5745,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5742,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5820,
+ "src": "35837:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5741,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "35837:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5744,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5820,
+ "src": "35846:5:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5743,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "35846:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "35836:16:7"
+ },
+ "scope": 8977,
+ "src": "35739:791:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 5905,
+ "nodeType": "Block",
+ "src": "36770:760:7",
+ "statements": [
+ {
+ "assignments": [
+ 5829
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5829,
+ "mutability": "mutable",
+ "name": "res",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5905,
+ "src": "36781:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5828,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "36781:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5831,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5830,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "36795:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "36781:15:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5834,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5832,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "36905:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5833,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "36910:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "36905:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5854,
+ "nodeType": "IfStatement",
+ "src": "36901:156:7",
+ "trueBody": {
+ "id": 5853,
+ "nodeType": "Block",
+ "src": "36919:138:7",
+ "statements": [
+ {
+ "assignments": [
+ 5836
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5836,
+ "mutability": "mutable",
+ "name": "count",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5853,
+ "src": "36934:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5835,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "36934:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5842,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5840,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5838,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "36958:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5839,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "36962:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "36958:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 5837,
+ "name": "floorLog2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5969,
+ "src": "36948:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint8_$",
+ "typeString": "function (uint256) pure returns (uint8)"
+ }
+ },
+ "id": 5841,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "36948:22:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "36934:36:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5845,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5843,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "36985:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": ">>=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 5844,
+ "name": "count",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5836,
+ "src": "36991:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "36985:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5846,
+ "nodeType": "ExpressionStatement",
+ "src": "36985:11:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5851,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5847,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5829,
+ "src": "37024:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5850,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5848,
+ "name": "count",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5836,
+ "src": "37030:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5849,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "37038:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37030:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37024:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5852,
+ "nodeType": "ExpressionStatement",
+ "src": "37024:21:7"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5857,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5855,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "37165:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5856,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "37169:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37165:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5898,
+ "nodeType": "IfStatement",
+ "src": "37161:305:7",
+ "trueBody": {
+ "id": 5897,
+ "nodeType": "Block",
+ "src": "37178:288:7",
+ "statements": [
+ {
+ "body": {
+ "id": 5895,
+ "nodeType": "Block",
+ "src": "37235:220:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5875,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5868,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "37254:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5874,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5871,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5869,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "37259:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5870,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "37263:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37259:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 5872,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "37258:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5873,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "37268:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37258:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37254:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5876,
+ "nodeType": "ExpressionStatement",
+ "src": "37254:21:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5879,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5877,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "37315:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5878,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "37320:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37315:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5894,
+ "nodeType": "IfStatement",
+ "src": "37311:129:7",
+ "trueBody": {
+ "id": 5893,
+ "nodeType": "Block",
+ "src": "37329:111:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5882,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5880,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "37352:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": ">>=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5881,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "37358:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "37352:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5883,
+ "nodeType": "ExpressionStatement",
+ "src": "37352:7:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5891,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5884,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5829,
+ "src": "37399:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5890,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5885,
+ "name": "ONE",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3574,
+ "src": "37406:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "id": 5888,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5886,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5859,
+ "src": "37414:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5887,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "37418:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "37414:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5889,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "37413:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "37406:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37399:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5892,
+ "nodeType": "ExpressionStatement",
+ "src": "37399:21:7"
+ }
+ ]
+ }
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "id": 5864,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5862,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5859,
+ "src": "37223:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5863,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "37227:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "37223:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 5896,
+ "initializationExpression": {
+ "assignments": [
+ 5859
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5859,
+ "mutability": "mutable",
+ "name": "i",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5896,
+ "src": "37198:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5858,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "37198:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5861,
+ "initialValue": {
+ "argumentTypes": null,
+ "id": 5860,
+ "name": "MAX_PRECISION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3583,
+ "src": "37208:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "37198:23:7"
+ },
+ "loopExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5866,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "--",
+ "prefix": true,
+ "src": "37230:3:7",
+ "subExpression": {
+ "argumentTypes": null,
+ "id": 5865,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5859,
+ "src": "37232:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "id": 5867,
+ "nodeType": "ExpressionStatement",
+ "src": "37230:3:7"
+ },
+ "nodeType": "ForStatement",
+ "src": "37193:262:7"
+ }
+ ]
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5903,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5901,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5899,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5829,
+ "src": "37485:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5900,
+ "name": "LN2_NUMERATOR",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3595,
+ "src": "37491:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37485:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5902,
+ "name": "LN2_DENOMINATOR",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3598,
+ "src": "37507:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37485:37:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5827,
+ "id": 5904,
+ "nodeType": "Return",
+ "src": "37478:44:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5821,
+ "nodeType": "StructuredDocumentation",
+ "src": "36538:163:7",
+ "text": " @dev computes log(x / FIXED_1) * FIXED_1.\n This functions assumes that \"x >= FIXED_1\", because the output would be negative otherwise."
+ },
+ "id": 5906,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "generalLog",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 5824,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5823,
+ "mutability": "mutable",
+ "name": "x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5906,
+ "src": "36727:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5822,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "36727:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "36726:11:7"
+ },
+ "returnParameters": {
+ "id": 5827,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5826,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5906,
+ "src": "36761:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5825,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "36761:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "36760:9:7"
+ },
+ "scope": 8977,
+ "src": "36707:823:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 5968,
+ "nodeType": "Block",
+ "src": "37719:481:7",
+ "statements": [
+ {
+ "assignments": [
+ 5915
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5915,
+ "mutability": "mutable",
+ "name": "res",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5968,
+ "src": "37730:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5914,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "37730:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5917,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5916,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "37742:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "37730:13:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5920,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5918,
+ "name": "_n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5909,
+ "src": "37760:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "323536",
+ "id": 5919,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "37765:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_256_by_1",
+ "typeString": "int_const 256"
+ },
+ "value": "256"
+ },
+ "src": "37760:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "id": 5964,
+ "nodeType": "Block",
+ "src": "37933:237:7",
+ "statements": [
+ {
+ "body": {
+ "id": 5962,
+ "nodeType": "Block",
+ "src": "38021:138:7",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5951,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5946,
+ "name": "_n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5909,
+ "src": "38044:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5949,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5947,
+ "name": "ONE",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3574,
+ "src": "38051:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5948,
+ "name": "s",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5936,
+ "src": "38058:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "38051:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 5950,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "38050:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "38044:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5961,
+ "nodeType": "IfStatement",
+ "src": "38040:104:7",
+ "trueBody": {
+ "id": 5960,
+ "nodeType": "Block",
+ "src": "38062:82:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5954,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5952,
+ "name": "_n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5909,
+ "src": "38085:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": ">>=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 5953,
+ "name": "s",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5936,
+ "src": "38092:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "38085:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5955,
+ "nodeType": "ExpressionStatement",
+ "src": "38085:8:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5958,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5956,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5915,
+ "src": "38116:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "|=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 5957,
+ "name": "s",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5936,
+ "src": "38123:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "38116:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "id": 5959,
+ "nodeType": "ExpressionStatement",
+ "src": "38116:8:7"
+ }
+ ]
+ }
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "id": 5941,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5939,
+ "name": "s",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5936,
+ "src": "38005:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5940,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "38009:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "38005:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 5963,
+ "initializationExpression": {
+ "assignments": [
+ 5936
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5936,
+ "mutability": "mutable",
+ "name": "s",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5963,
+ "src": "37990:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5935,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "37990:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5938,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "313238",
+ "id": 5937,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "38000:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_128_by_1",
+ "typeString": "int_const 128"
+ },
+ "value": "128"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "37990:13:7"
+ },
+ "loopExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5944,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5942,
+ "name": "s",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5936,
+ "src": "38012:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": ">>=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5943,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "38018:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "38012:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "id": 5945,
+ "nodeType": "ExpressionStatement",
+ "src": "38012:7:7"
+ },
+ "nodeType": "ForStatement",
+ "src": "37985:174:7"
+ }
+ ]
+ },
+ "id": 5965,
+ "nodeType": "IfStatement",
+ "src": "37756:414:7",
+ "trueBody": {
+ "id": 5934,
+ "nodeType": "Block",
+ "src": "37770:148:7",
+ "statements": [
+ {
+ "body": {
+ "id": 5932,
+ "nodeType": "Block",
+ "src": "37837:70:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5926,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5924,
+ "name": "_n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5909,
+ "src": "37856:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": ">>=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5925,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "37863:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "37856:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5927,
+ "nodeType": "ExpressionStatement",
+ "src": "37856:8:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5930,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5928,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5915,
+ "src": "37883:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5929,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "37890:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "37883:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "id": 5931,
+ "nodeType": "ExpressionStatement",
+ "src": "37883:8:7"
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5923,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5921,
+ "name": "_n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5909,
+ "src": "37829:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5922,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "37834:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "37829:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 5933,
+ "nodeType": "WhileStatement",
+ "src": "37822:85:7"
+ }
+ ]
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5966,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5915,
+ "src": "38189:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "functionReturnParameters": 5913,
+ "id": 5967,
+ "nodeType": "Return",
+ "src": "38182:10:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5907,
+ "nodeType": "StructuredDocumentation",
+ "src": "37538:114:7",
+ "text": " @dev computes the largest integer smaller than or equal to the binary logarithm of the input."
+ },
+ "id": 5969,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "floorLog2",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 5910,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5909,
+ "mutability": "mutable",
+ "name": "_n",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5969,
+ "src": "37677:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5908,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "37677:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "37676:12:7"
+ },
+ "returnParameters": {
+ "id": 5913,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5912,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5969,
+ "src": "37712:5:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5911,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "37712:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "37711:7:7"
+ },
+ "scope": 8977,
+ "src": "37658:542:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 6035,
+ "nodeType": "Block",
+ "src": "38650:424:7",
+ "statements": [
+ {
+ "assignments": [
+ 5978
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5978,
+ "mutability": "mutable",
+ "name": "lo",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6035,
+ "src": "38661:8:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5977,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "38661:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5980,
+ "initialValue": {
+ "argumentTypes": null,
+ "id": 5979,
+ "name": "MIN_PRECISION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3580,
+ "src": "38672:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "38661:24:7"
+ },
+ {
+ "assignments": [
+ 5982
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5982,
+ "mutability": "mutable",
+ "name": "hi",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6035,
+ "src": "38696:8:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5981,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "38696:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5984,
+ "initialValue": {
+ "argumentTypes": null,
+ "id": 5983,
+ "name": "MAX_PRECISION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3583,
+ "src": "38707:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "38696:24:7"
+ },
+ {
+ "body": {
+ "id": 6013,
+ "nodeType": "Block",
+ "src": "38753:165:7",
+ "statements": [
+ {
+ "assignments": [
+ 5991
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5991,
+ "mutability": "mutable",
+ "name": "mid",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6013,
+ "src": "38768:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5990,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "38768:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5998,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "id": 5997,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "id": 5994,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5992,
+ "name": "lo",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5978,
+ "src": "38781:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5993,
+ "name": "hi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5982,
+ "src": "38786:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "38781:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5995,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "38780:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 5996,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "38792:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "38780:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "38768:25:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6003,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 5999,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "38812:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 6001,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 6000,
+ "name": "mid",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5991,
+ "src": "38824:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "38812:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6002,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5972,
+ "src": "38832:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "38812:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6010,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6008,
+ "name": "hi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5982,
+ "src": "38898:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 6009,
+ "name": "mid",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5991,
+ "src": "38903:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "38898:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "id": 6011,
+ "nodeType": "ExpressionStatement",
+ "src": "38898:8:7"
+ },
+ "id": 6012,
+ "nodeType": "IfStatement",
+ "src": "38808:98:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6006,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6004,
+ "name": "lo",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5978,
+ "src": "38853:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 6005,
+ "name": "mid",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5991,
+ "src": "38858:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "38853:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "id": 6007,
+ "nodeType": "ExpressionStatement",
+ "src": "38853:8:7"
+ }
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "id": 5989,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "id": 5987,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5985,
+ "name": "lo",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5978,
+ "src": "38740:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5986,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "38745:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "38740:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5988,
+ "name": "hi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5982,
+ "src": "38749:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "38740:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 6014,
+ "nodeType": "WhileStatement",
+ "src": "38733:185:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6019,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 6015,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "38934:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 6017,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 6016,
+ "name": "hi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5982,
+ "src": "38946:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "38934:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6018,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5972,
+ "src": "38953:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "38934:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6022,
+ "nodeType": "IfStatement",
+ "src": "38930:49:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6020,
+ "name": "hi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5982,
+ "src": "38977:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "functionReturnParameters": 5976,
+ "id": 6021,
+ "nodeType": "Return",
+ "src": "38970:9:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6027,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 6023,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "38994:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 6025,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 6024,
+ "name": "lo",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5978,
+ "src": "39006:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "38994:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6026,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5972,
+ "src": "39013:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "38994:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6030,
+ "nodeType": "IfStatement",
+ "src": "38990:49:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6028,
+ "name": "lo",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5978,
+ "src": "39037:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "functionReturnParameters": 5976,
+ "id": 6029,
+ "nodeType": "Return",
+ "src": "39030:9:7"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "66616c7365",
+ "id": 6032,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "39060:5:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "false"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ ],
+ "id": 6031,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "39052:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
+ "typeString": "function (bool) pure"
+ }
+ },
+ "id": 6033,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "39052:14:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 6034,
+ "nodeType": "ExpressionStatement",
+ "src": "39052:14:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5970,
+ "nodeType": "StructuredDocumentation",
+ "src": "38208:359:7",
+ "text": " @dev the global \"maxExpArray\" is sorted in descending order, and therefore the following statements are equivalent:\n - This function finds the position of [the smallest value in \"maxExpArray\" larger than or equal to \"x\"]\n - This function finds the highest position of [a value in \"maxExpArray\" larger than or equal to \"x\"]"
+ },
+ "id": 6036,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "findPositionInMaxExpArray",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 5973,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5972,
+ "mutability": "mutable",
+ "name": "_x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6036,
+ "src": "38608:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5971,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "38608:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "38607:12:7"
+ },
+ "returnParameters": {
+ "id": 5976,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5975,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6036,
+ "src": "38643:5:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5974,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "38643:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "38642:7:7"
+ },
+ "scope": 8977,
+ "src": "38573:501:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 6545,
+ "nodeType": "Block",
+ "src": "39728:3782:7",
+ "statements": [
+ {
+ "assignments": [
+ 6047
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6047,
+ "mutability": "mutable",
+ "name": "xi",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6545,
+ "src": "39739:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6046,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "39739:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6049,
+ "initialValue": {
+ "argumentTypes": null,
+ "id": 6048,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "39752:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "39739:15:7"
+ },
+ {
+ "assignments": [
+ 6051
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6051,
+ "mutability": "mutable",
+ "name": "res",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6545,
+ "src": "39765:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6050,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "39765:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6053,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 6052,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "39779:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "39765:15:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6061,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6054,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "39793:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6060,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6057,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6055,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "39799:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6056,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "39804:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "39799:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6058,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "39798:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6059,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "39811:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "39798:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "39793:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6062,
+ "nodeType": "ExpressionStatement",
+ "src": "39793:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6067,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6063,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "39823:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6066,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6064,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "39830:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307833343432633465363037346138326631373937663732616330303030303030",
+ "id": 6065,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "39835:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4341658809405943247759097200640000000_by_1",
+ "typeString": "int_const 4341...(29 digits omitted)...0000"
+ },
+ "value": "0x3442c4e6074a82f1797f72ac0000000"
+ },
+ "src": "39830:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "39823:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6068,
+ "nodeType": "ExpressionStatement",
+ "src": "39823:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6076,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6069,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "39905:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6075,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6072,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6070,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "39911:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6071,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "39916:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "39911:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6073,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "39910:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6074,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "39923:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "39910:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "39905:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6077,
+ "nodeType": "ExpressionStatement",
+ "src": "39905:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6082,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6078,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "39935:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6081,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6079,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "39942:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307831313662393666373537633338306662323837666430653430303030303030",
+ "id": 6080,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "39947:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1447219603135314415919699066880000000_by_1",
+ "typeString": "int_const 1447...(29 digits omitted)...0000"
+ },
+ "value": "0x116b96f757c380fb287fd0e40000000"
+ },
+ "src": "39942:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "39935:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6083,
+ "nodeType": "ExpressionStatement",
+ "src": "39935:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6091,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6084,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40017:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6090,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6087,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6085,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40023:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6086,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40028:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40023:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6088,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40022:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6089,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40035:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40022:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40017:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6092,
+ "nodeType": "ExpressionStatement",
+ "src": "40017:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6097,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6093,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40047:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6096,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6094,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40054:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830343561653562646435663065303365636131666634333930303030303030",
+ "id": 6095,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40059:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_361804900783828603979924766720000000_by_1",
+ "typeString": "int_const 3618...(28 digits omitted)...0000"
+ },
+ "value": "0x045ae5bdd5f0e03eca1ff4390000000"
+ },
+ "src": "40054:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40047:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6098,
+ "nodeType": "ExpressionStatement",
+ "src": "40047:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6106,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6099,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40129:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6105,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6102,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6100,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40135:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6101,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40140:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40135:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6103,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40134:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6104,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40147:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40134:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40129:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6107,
+ "nodeType": "ExpressionStatement",
+ "src": "40129:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6112,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6108,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40159:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6111,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6109,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40166:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830306465666162663931333032636439356239666664613530303030303030",
+ "id": 6110,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40171:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_72360980156765720795984953344000000_by_1",
+ "typeString": "int_const 7236...(27 digits omitted)...0000"
+ },
+ "value": "0x00defabf91302cd95b9ffda50000000"
+ },
+ "src": "40166:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40159:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6113,
+ "nodeType": "ExpressionStatement",
+ "src": "40159:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6121,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6114,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40241:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6120,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6117,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6115,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40247:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6116,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40252:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40247:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6118,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40246:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6119,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40259:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40246:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40241:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6122,
+ "nodeType": "ExpressionStatement",
+ "src": "40241:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6127,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6123,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40271:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6126,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6124,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40278:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303235323963613938333262323234333965666666396238303030303030",
+ "id": 6125,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40283:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_12060163359460953465997492224000000_by_1",
+ "typeString": "int_const 1206...(27 digits omitted)...0000"
+ },
+ "value": "0x002529ca9832b22439efff9b8000000"
+ },
+ "src": "40278:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40271:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6128,
+ "nodeType": "ExpressionStatement",
+ "src": "40271:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6136,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6129,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40353:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6135,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6132,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6130,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40359:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6131,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40364:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40359:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6133,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40358:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6134,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40371:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40358:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40353:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6137,
+ "nodeType": "ExpressionStatement",
+ "src": "40353:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6142,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6138,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40383:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6141,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6139,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40390:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303035346631636631326264303465353136623664613838303030303030",
+ "id": 6140,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40395:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1722880479922993352285356032000000_by_1",
+ "typeString": "int_const 1722...(26 digits omitted)...0000"
+ },
+ "value": "0x00054f1cf12bd04e516b6da88000000"
+ },
+ "src": "40390:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40383:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6143,
+ "nodeType": "ExpressionStatement",
+ "src": "40383:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6151,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6144,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40465:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6150,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6147,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6145,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40471:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6146,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40476:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40471:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6148,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40470:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6149,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40483:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40470:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40465:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6152,
+ "nodeType": "ExpressionStatement",
+ "src": "40465:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6157,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6153,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40495:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6156,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6154,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40502:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030613965333965323537613039636132643664623531303030303030",
+ "id": 6155,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40507:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_215360059990374169035669504000000_by_1",
+ "typeString": "int_const 2153...(25 digits omitted)...0000"
+ },
+ "value": "0x0000a9e39e257a09ca2d6db51000000"
+ },
+ "src": "40502:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40495:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6158,
+ "nodeType": "ExpressionStatement",
+ "src": "40495:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6166,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6159,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40577:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6165,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6162,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6160,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40583:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6161,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40588:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40583:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6163,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40582:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6164,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40595:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40582:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40577:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6167,
+ "nodeType": "ExpressionStatement",
+ "src": "40577:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6172,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6168,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40607:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6171,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6169,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40614:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030313265303636653762383339666130353063333039303030303030",
+ "id": 6170,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40619:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_23928895554486018781741056000000_by_1",
+ "typeString": "int_const 23928895554486018781741056000000"
+ },
+ "value": "0x000012e066e7b839fa050c309000000"
+ },
+ "src": "40614:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40607:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6173,
+ "nodeType": "ExpressionStatement",
+ "src": "40607:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6181,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6174,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40689:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6180,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6177,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6175,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40695:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6176,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40700:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40695:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6178,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40694:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6179,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40707:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40694:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40689:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6182,
+ "nodeType": "ExpressionStatement",
+ "src": "40689:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6187,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6183,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40719:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6186,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6184,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40726:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303165333364376439323663333239613161643161383030303030",
+ "id": 6185,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40731:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2392889555448601878174105600000_by_1",
+ "typeString": "int_const 2392889555448601878174105600000"
+ },
+ "value": "0x000001e33d7d926c329a1ad1a800000"
+ },
+ "src": "40726:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40719:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6188,
+ "nodeType": "ExpressionStatement",
+ "src": "40719:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6196,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6189,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40801:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6195,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6192,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6190,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40807:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6191,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40812:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40807:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6193,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40806:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6194,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40819:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40806:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40801:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6197,
+ "nodeType": "ExpressionStatement",
+ "src": "40801:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6202,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6198,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40831:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6201,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6199,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40838:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303032626565353133626462346136623139623566383030303030",
+ "id": 6200,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40843:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_217535414131691079834009600000_by_1",
+ "typeString": "int_const 217535414131691079834009600000"
+ },
+ "value": "0x0000002bee513bdb4a6b19b5f800000"
+ },
+ "src": "40838:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40831:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6203,
+ "nodeType": "ExpressionStatement",
+ "src": "40831:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6211,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6204,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40913:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6210,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6207,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6205,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40919:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6206,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40924:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40919:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6208,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40918:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6209,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40931:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40918:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40913:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6212,
+ "nodeType": "ExpressionStatement",
+ "src": "40913:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6217,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6213,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40943:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6216,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6214,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40950:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030336139333136666137396238386563636632613030303030",
+ "id": 6215,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40955:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_18127951177640923319500800000_by_1",
+ "typeString": "int_const 18127951177640923319500800000"
+ },
+ "value": "0x00000003a9316fa79b88eccf2a00000"
+ },
+ "src": "40950:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40943:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6218,
+ "nodeType": "ExpressionStatement",
+ "src": "40943:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6226,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6219,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41025:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6225,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6222,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6220,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41031:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6221,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41036:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41031:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6223,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41030:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6224,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41043:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41030:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41025:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6227,
+ "nodeType": "ExpressionStatement",
+ "src": "41025:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6232,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6228,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41055:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6231,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6229,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41062:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303438313737656265316661383132333735323030303030",
+ "id": 6230,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41067:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1394457782895455639961600000_by_1",
+ "typeString": "int_const 1394457782895455639961600000"
+ },
+ "value": "0x0000000048177ebe1fa812375200000"
+ },
+ "src": "41062:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41055:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6233,
+ "nodeType": "ExpressionStatement",
+ "src": "41055:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6241,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6234,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41137:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6240,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6237,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6235,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41143:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6236,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41148:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41143:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6238,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41142:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6239,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41155:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41142:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41137:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6242,
+ "nodeType": "ExpressionStatement",
+ "src": "41137:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6247,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6243,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41167:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6246,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6244,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41174:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303035323633666539303234326463626163663030303030",
+ "id": 6245,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41179:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_99604127349675402854400000_by_1",
+ "typeString": "int_const 99604127349675402854400000"
+ },
+ "value": "0x0000000005263fe90242dcbacf00000"
+ },
+ "src": "41174:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41167:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6248,
+ "nodeType": "ExpressionStatement",
+ "src": "41167:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6256,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6249,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41249:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6255,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6252,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6250,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41255:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6251,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41260:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41255:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6253,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41254:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6254,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41267:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41254:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41249:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6257,
+ "nodeType": "ExpressionStatement",
+ "src": "41249:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6262,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6258,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41279:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6261,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6259,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41286:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030353765323230393963303330643934313030303030",
+ "id": 6260,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41291:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6640275156645026856960000_by_1",
+ "typeString": "int_const 6640275156645026856960000"
+ },
+ "value": "0x000000000057e22099c030d94100000"
+ },
+ "src": "41286:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41279:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6263,
+ "nodeType": "ExpressionStatement",
+ "src": "41279:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6271,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6264,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41361:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6270,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6267,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6265,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41367:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6266,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41372:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41367:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6268,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41366:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6269,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41379:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41366:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41361:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6272,
+ "nodeType": "ExpressionStatement",
+ "src": "41361:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6277,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6273,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41391:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6276,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6274,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41398:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303537653232303939633033306439343130303030",
+ "id": 6275,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41403:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_415017197290314178560000_by_1",
+ "typeString": "int_const 415017197290314178560000"
+ },
+ "value": "0x0000000000057e22099c030d9410000"
+ },
+ "src": "41398:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41391:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6278,
+ "nodeType": "ExpressionStatement",
+ "src": "41391:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6286,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6279,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41473:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6285,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6282,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6280,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41479:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6281,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41484:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41479:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6283,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41478:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6284,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41491:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41478:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41473:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6287,
+ "nodeType": "ExpressionStatement",
+ "src": "41473:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6292,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6288,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41503:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6291,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6289,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41510:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303035326236623534353639393736333130303030",
+ "id": 6290,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41515:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_24412776311194951680000_by_1",
+ "typeString": "int_const 24412776311194951680000"
+ },
+ "value": "0x00000000000052b6b54569976310000"
+ },
+ "src": "41510:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41503:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6293,
+ "nodeType": "ExpressionStatement",
+ "src": "41503:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6301,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6294,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41585:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6300,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6297,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6295,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41591:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6296,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41596:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41591:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6298,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41590:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6299,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41603:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41590:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41585:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6302,
+ "nodeType": "ExpressionStatement",
+ "src": "41585:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6307,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6303,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41615:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6306,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6304,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41622:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030343938356636373639366266373438303030",
+ "id": 6305,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41627:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1356265350621941760000_by_1",
+ "typeString": "int_const 1356265350621941760000"
+ },
+ "value": "0x00000000000004985f67696bf748000"
+ },
+ "src": "41622:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41615:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6308,
+ "nodeType": "ExpressionStatement",
+ "src": "41615:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6316,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6309,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41697:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6315,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6312,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6310,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41703:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6311,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41708:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41703:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6313,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41702:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6314,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41715:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41702:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41697:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6317,
+ "nodeType": "ExpressionStatement",
+ "src": "41697:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6322,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6318,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41727:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6321,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6319,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41734:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303364656131326561393965343938303030",
+ "id": 6320,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41739:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_71382386874839040000_by_1",
+ "typeString": "int_const 71382386874839040000"
+ },
+ "value": "0x000000000000003dea12ea99e498000"
+ },
+ "src": "41734:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41727:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6323,
+ "nodeType": "ExpressionStatement",
+ "src": "41727:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6331,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6324,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41809:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6330,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6327,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6325,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41815:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6326,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41820:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41815:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6328,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41814:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6329,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41827:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41814:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41809:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6332,
+ "nodeType": "ExpressionStatement",
+ "src": "41809:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6337,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6333,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41839:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6336,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6334,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41846:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303033313838306632323134623665303030",
+ "id": 6335,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41851:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3569119343741952000_by_1",
+ "typeString": "int_const 3569119343741952000"
+ },
+ "value": "0x00000000000000031880f2214b6e000"
+ },
+ "src": "41846:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41839:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6338,
+ "nodeType": "ExpressionStatement",
+ "src": "41839:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6346,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6339,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41921:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6345,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6342,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6340,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41927:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6341,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41932:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41927:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6343,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41926:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6344,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41939:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41926:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41921:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6347,
+ "nodeType": "ExpressionStatement",
+ "src": "41921:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6352,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6348,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41951:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6351,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6349,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41958:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030323562636666353665623336303030",
+ "id": 6350,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41963:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_169958063987712000_by_1",
+ "typeString": "int_const 169958063987712000"
+ },
+ "value": "0x000000000000000025bcff56eb36000"
+ },
+ "src": "41958:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41951:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6353,
+ "nodeType": "ExpressionStatement",
+ "src": "41951:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6361,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6354,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42033:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6360,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6357,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6355,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42039:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6356,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42044:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42039:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6358,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42038:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6359,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42051:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42038:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42033:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6362,
+ "nodeType": "ExpressionStatement",
+ "src": "42033:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6367,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6363,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42063:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6366,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6364,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42070:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303162373232653130616231303030",
+ "id": 6365,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42075:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_7725366544896000_by_1",
+ "typeString": "int_const 7725366544896000"
+ },
+ "value": "0x000000000000000001b722e10ab1000"
+ },
+ "src": "42070:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42063:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6368,
+ "nodeType": "ExpressionStatement",
+ "src": "42063:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6376,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6369,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42145:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6375,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6372,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6370,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42151:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6371,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42156:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42151:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6373,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42150:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6374,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42163:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42150:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42145:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6377,
+ "nodeType": "ExpressionStatement",
+ "src": "42145:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6382,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6378,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42175:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6381,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6379,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42182:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303031333137633730303737303030",
+ "id": 6380,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42187:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_335885501952000_by_1",
+ "typeString": "int_const 335885501952000"
+ },
+ "value": "0x0000000000000000001317c70077000"
+ },
+ "src": "42182:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42175:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6383,
+ "nodeType": "ExpressionStatement",
+ "src": "42175:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6391,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6384,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42257:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6390,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6387,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6385,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42263:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6386,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42268:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42263:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6388,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42262:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6389,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42275:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42262:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42257:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6392,
+ "nodeType": "ExpressionStatement",
+ "src": "42257:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6397,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6393,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42287:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6396,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6394,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42294:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030306362613834616166613030",
+ "id": 6395,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42299:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_13995229248000_by_1",
+ "typeString": "int_const 13995229248000"
+ },
+ "value": "0x00000000000000000000cba84aafa00"
+ },
+ "src": "42294:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42287:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6398,
+ "nodeType": "ExpressionStatement",
+ "src": "42287:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6406,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6399,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42369:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6405,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6402,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6400,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42375:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6401,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42380:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42375:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6403,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42374:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6404,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42387:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42374:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42369:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6407,
+ "nodeType": "ExpressionStatement",
+ "src": "42369:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6412,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6408,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42399:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6411,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6409,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42406:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303038323537336130613030",
+ "id": 6410,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42411:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_559809169920_by_1",
+ "typeString": "int_const 559809169920"
+ },
+ "value": "0x00000000000000000000082573a0a00"
+ },
+ "src": "42406:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42399:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6413,
+ "nodeType": "ExpressionStatement",
+ "src": "42399:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6421,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6414,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42481:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6420,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6417,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6415,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42487:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6416,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42492:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42487:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6418,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42486:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6419,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42499:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42486:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42481:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6422,
+ "nodeType": "ExpressionStatement",
+ "src": "42481:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6427,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6423,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42511:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6426,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6424,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42518:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303030353033356164393030",
+ "id": 6425,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42523:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_21531121920_by_1",
+ "typeString": "int_const 21531121920"
+ },
+ "value": "0x00000000000000000000005035ad900"
+ },
+ "src": "42518:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42511:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6428,
+ "nodeType": "ExpressionStatement",
+ "src": "42511:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6436,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6429,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42593:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6435,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6432,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6430,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42599:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6431,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42604:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42599:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6433,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42598:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6434,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42611:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42598:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42593:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6437,
+ "nodeType": "ExpressionStatement",
+ "src": "42593:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6442,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6438,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42623:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6441,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6439,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42630:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303030303266383831623030",
+ "id": 6440,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42635:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_797448960_by_1",
+ "typeString": "int_const 797448960"
+ },
+ "value": "0x000000000000000000000002f881b00"
+ },
+ "src": "42630:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42623:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6443,
+ "nodeType": "ExpressionStatement",
+ "src": "42623:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6451,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6444,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42705:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6450,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6447,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6445,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42711:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6446,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42716:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42711:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6448,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42710:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6449,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42723:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42710:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42705:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6452,
+ "nodeType": "ExpressionStatement",
+ "src": "42705:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6457,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6453,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42735:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6456,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6454,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42742:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303030303031623239333430",
+ "id": 6455,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42747:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_28480320_by_1",
+ "typeString": "int_const 28480320"
+ },
+ "value": "0x0000000000000000000000001b29340"
+ },
+ "src": "42742:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42735:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6458,
+ "nodeType": "ExpressionStatement",
+ "src": "42735:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6466,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6459,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42817:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6465,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6462,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6460,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42823:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6461,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42828:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42823:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6463,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42822:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6464,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42835:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42822:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42817:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6467,
+ "nodeType": "ExpressionStatement",
+ "src": "42817:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6472,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6468,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42847:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6471,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6469,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42854:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303030303030306566633430",
+ "id": 6470,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42859:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_982080_by_1",
+ "typeString": "int_const 982080"
+ },
+ "value": "0x00000000000000000000000000efc40"
+ },
+ "src": "42854:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42847:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6473,
+ "nodeType": "ExpressionStatement",
+ "src": "42847:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6481,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6474,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42929:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6480,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6477,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6475,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42935:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6476,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42940:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42935:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6478,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42934:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6479,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42947:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42934:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42929:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6482,
+ "nodeType": "ExpressionStatement",
+ "src": "42929:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6487,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6483,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42959:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6486,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6484,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42966:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303030303030303037666530",
+ "id": 6485,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42971:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_32736_by_1",
+ "typeString": "int_const 32736"
+ },
+ "value": "0x0000000000000000000000000007fe0"
+ },
+ "src": "42966:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42959:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6488,
+ "nodeType": "ExpressionStatement",
+ "src": "42959:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6496,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6489,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43041:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6495,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6492,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6490,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43047:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6491,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "43052:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43047:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6493,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "43046:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6494,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "43059:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "43046:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43041:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6497,
+ "nodeType": "ExpressionStatement",
+ "src": "43041:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6502,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6498,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "43071:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6501,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6499,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43078:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303030303030303030343230",
+ "id": 6500,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "43083:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1056_by_1",
+ "typeString": "int_const 1056"
+ },
+ "value": "0x0000000000000000000000000000420"
+ },
+ "src": "43078:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43071:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6503,
+ "nodeType": "ExpressionStatement",
+ "src": "43071:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6511,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6504,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43153:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6510,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6507,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6505,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43159:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6506,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "43164:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43159:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6508,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "43158:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6509,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "43171:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "43158:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43153:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6512,
+ "nodeType": "ExpressionStatement",
+ "src": "43153:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6517,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6513,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "43183:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6516,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6514,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43190:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303030303030303030303231",
+ "id": 6515,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "43195:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_33_by_1",
+ "typeString": "int_const 33"
+ },
+ "value": "0x0000000000000000000000000000021"
+ },
+ "src": "43190:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43183:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6518,
+ "nodeType": "ExpressionStatement",
+ "src": "43183:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6526,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6519,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43265:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6525,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6522,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6520,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43271:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6521,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "43276:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43271:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6523,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "43270:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6524,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "43283:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "43270:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43265:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6527,
+ "nodeType": "ExpressionStatement",
+ "src": "43265:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6532,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6528,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "43295:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6531,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6529,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43302:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303030303030303030303031",
+ "id": 6530,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "43307:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "0x0000000000000000000000000000001"
+ },
+ "src": "43302:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43295:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6533,
+ "nodeType": "ExpressionStatement",
+ "src": "43295:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6543,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6538,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6536,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6534,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "43386:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307836383835383963633065393530356532663266656535353830303030303030",
+ "id": 6535,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "43392:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_8683317618811886495518194401280000000_by_1",
+ "typeString": "int_const 8683...(29 digits omitted)...0000"
+ },
+ "value": "0x688589cc0e9505e2f2fee5580000000"
+ },
+ "src": "43386:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6537,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "43428:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43386:44:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6541,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6539,
+ "name": "ONE",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3574,
+ "src": "43434:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6540,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "43441:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "43434:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6542,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "43433:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43386:66:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 6045,
+ "id": 6544,
+ "nodeType": "Return",
+ "src": "43379:73:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 6037,
+ "nodeType": "StructuredDocumentation",
+ "src": "39082:558:7",
+ "text": " @dev this function can be auto-generated by the script 'PrintFunctionGeneralExp.py'.\n it approximates \"e ^ x\" via maclaurin summation: \"(x^0)/0! + (x^1)/1! + ... + (x^n)/n!\".\n it returns \"e ^ (x / 2 ^ precision) * 2 ^ precision\", that is, the result is upshifted for accuracy.\n the global \"maxExpArray\" maps each \"precision\" to \"((maximumExponent + 1) << (MAX_PRECISION - precision)) - 1\".\n the maximum permitted value for \"x\" is therefore given by \"maxExpArray[precision] >> (MAX_PRECISION - precision)\"."
+ },
+ "id": 6546,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "generalExp",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 6042,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 6039,
+ "mutability": "mutable",
+ "name": "_x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6546,
+ "src": "39666:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6038,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "39666:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 6041,
+ "mutability": "mutable",
+ "name": "_precision",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6546,
+ "src": "39678:16:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 6040,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "39678:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "39665:30:7"
+ },
+ "returnParameters": {
+ "id": 6045,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 6044,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6546,
+ "src": "39719:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6043,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "39719:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "39718:9:7"
+ },
+ "scope": 8977,
+ "src": "39646:3864:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 6865,
+ "nodeType": "Block",
+ "src": "44315:2735:7",
+ "statements": [
+ {
+ "assignments": [
+ 6555
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6555,
+ "mutability": "mutable",
+ "name": "res",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6865,
+ "src": "44326:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6554,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "44326:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6557,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 6556,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44340:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "44326:15:7"
+ },
+ {
+ "assignments": [
+ 6559
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6559,
+ "mutability": "mutable",
+ "name": "y",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6865,
+ "src": "44354:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6558,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "44354:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6560,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "44354:9:7"
+ },
+ {
+ "assignments": [
+ 6562
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6562,
+ "mutability": "mutable",
+ "name": "z",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6865,
+ "src": "44374:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6561,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "44374:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6563,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "44374:9:7"
+ },
+ {
+ "assignments": [
+ 6565
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6565,
+ "mutability": "mutable",
+ "name": "w",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6865,
+ "src": "44394:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6564,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "44394:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6566,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "44394:9:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6569,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6567,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44420:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30786433303934633730663033346465346239366666376435623666393966636438",
+ "id": 6568,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44425:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_280515388193368458015406427511040113880_by_1",
+ "typeString": "int_const 2805...(31 digits omitted)...3880"
+ },
+ "value": "0xd3094c70f034de4b96ff7d5b6f99fcd8"
+ },
+ "src": "44420:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6583,
+ "nodeType": "IfStatement",
+ "src": "44416:143:7",
+ "trueBody": {
+ "id": 6582,
+ "nodeType": "Block",
+ "src": "44461:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6572,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6570,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "44462:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783430303030303030303030303030303030303030303030303030303030303030",
+ "id": 6571,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44469:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_85070591730234615865843651857942052864_by_1",
+ "typeString": "int_const 8507...(30 digits omitted)...2864"
+ },
+ "value": "0x40000000000000000000000000000000"
+ },
+ "src": "44462:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6573,
+ "nodeType": "ExpressionStatement",
+ "src": "44462:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6580,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6574,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44505:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6579,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6577,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6575,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44509:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6576,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "44513:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "44509:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30786433303934633730663033346465346239366666376435623666393966636438",
+ "id": 6578,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44523:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_280515388193368458015406427511040113880_by_1",
+ "typeString": "int_const 2805...(31 digits omitted)...3880"
+ },
+ "value": "0xd3094c70f034de4b96ff7d5b6f99fcd8"
+ },
+ "src": "44509:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "44505:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6581,
+ "nodeType": "ExpressionStatement",
+ "src": "44505:52:7"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6586,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6584,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44588:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30786134356166316531663430633333336233646531646234646435356632396137",
+ "id": 6585,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44593:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_218465603988574474844591417643679820199_by_1",
+ "typeString": "int_const 2184...(31 digits omitted)...0199"
+ },
+ "value": "0xa45af1e1f40c333b3de1db4dd55f29a7"
+ },
+ "src": "44588:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6600,
+ "nodeType": "IfStatement",
+ "src": "44584:143:7",
+ "trueBody": {
+ "id": 6599,
+ "nodeType": "Block",
+ "src": "44629:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6589,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6587,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "44630:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783230303030303030303030303030303030303030303030303030303030303030",
+ "id": 6588,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44637:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_42535295865117307932921825928971026432_by_1",
+ "typeString": "int_const 4253...(30 digits omitted)...6432"
+ },
+ "value": "0x20000000000000000000000000000000"
+ },
+ "src": "44630:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6590,
+ "nodeType": "ExpressionStatement",
+ "src": "44630:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6597,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6591,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44673:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6596,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6594,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6592,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44677:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6593,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "44681:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "44677:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30786134356166316531663430633333336233646531646234646435356632396137",
+ "id": 6595,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44691:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_218465603988574474844591417643679820199_by_1",
+ "typeString": "int_const 2184...(31 digits omitted)...0199"
+ },
+ "value": "0xa45af1e1f40c333b3de1db4dd55f29a7"
+ },
+ "src": "44677:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "44673:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6598,
+ "nodeType": "ExpressionStatement",
+ "src": "44673:52:7"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6603,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6601,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44756:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783931306230323264623761653637636537366234343163323730333563366131",
+ "id": 6602,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44761:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_192795218841189805222451540510555621025_by_1",
+ "typeString": "int_const 1927...(31 digits omitted)...1025"
+ },
+ "value": "0x910b022db7ae67ce76b441c27035c6a1"
+ },
+ "src": "44756:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6617,
+ "nodeType": "IfStatement",
+ "src": "44752:143:7",
+ "trueBody": {
+ "id": 6616,
+ "nodeType": "Block",
+ "src": "44797:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6606,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6604,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "44798:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783130303030303030303030303030303030303030303030303030303030303030",
+ "id": 6605,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44805:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_21267647932558653966460912964485513216_by_1",
+ "typeString": "int_const 2126...(30 digits omitted)...3216"
+ },
+ "value": "0x10000000000000000000000000000000"
+ },
+ "src": "44798:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6607,
+ "nodeType": "ExpressionStatement",
+ "src": "44798:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6614,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6608,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44841:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6613,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6611,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6609,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44845:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6610,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "44849:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "44845:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783931306230323264623761653637636537366234343163323730333563366131",
+ "id": 6612,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44859:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_192795218841189805222451540510555621025_by_1",
+ "typeString": "int_const 1927...(31 digits omitted)...1025"
+ },
+ "value": "0x910b022db7ae67ce76b441c27035c6a1"
+ },
+ "src": "44845:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "44841:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6615,
+ "nodeType": "ExpressionStatement",
+ "src": "44841:52:7"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6620,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6618,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44924:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783838343135616262653961373662656164386430306366313132653464346138",
+ "id": 6619,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44929:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_181114347027396448854165353426875372712_by_1",
+ "typeString": "int_const 1811...(31 digits omitted)...2712"
+ },
+ "value": "0x88415abbe9a76bead8d00cf112e4d4a8"
+ },
+ "src": "44924:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6634,
+ "nodeType": "IfStatement",
+ "src": "44920:143:7",
+ "trueBody": {
+ "id": 6633,
+ "nodeType": "Block",
+ "src": "44965:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6623,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6621,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "44966:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783038303030303030303030303030303030303030303030303030303030303030",
+ "id": 6622,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44973:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_10633823966279326983230456482242756608_by_1",
+ "typeString": "int_const 1063...(30 digits omitted)...6608"
+ },
+ "value": "0x08000000000000000000000000000000"
+ },
+ "src": "44966:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6624,
+ "nodeType": "ExpressionStatement",
+ "src": "44966:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6631,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6625,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45009:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6630,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6628,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6626,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45013:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6627,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "45017:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45013:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783838343135616262653961373662656164386430306366313132653464346138",
+ "id": 6629,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45027:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_181114347027396448854165353426875372712_by_1",
+ "typeString": "int_const 1811...(31 digits omitted)...2712"
+ },
+ "value": "0x88415abbe9a76bead8d00cf112e4d4a8"
+ },
+ "src": "45013:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45009:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6632,
+ "nodeType": "ExpressionStatement",
+ "src": "45009:52:7"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6637,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6635,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45092:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783834313032623030383933663634633730356538343164356434303634626433",
+ "id": 6636,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45097:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_175542044379434494067323265867529472979_by_1",
+ "typeString": "int_const 1755...(31 digits omitted)...2979"
+ },
+ "value": "0x84102b00893f64c705e841d5d4064bd3"
+ },
+ "src": "45092:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6651,
+ "nodeType": "IfStatement",
+ "src": "45088:143:7",
+ "trueBody": {
+ "id": 6650,
+ "nodeType": "Block",
+ "src": "45133:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6640,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6638,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "45134:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783034303030303030303030303030303030303030303030303030303030303030",
+ "id": 6639,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45141:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_5316911983139663491615228241121378304_by_1",
+ "typeString": "int_const 5316...(29 digits omitted)...8304"
+ },
+ "value": "0x04000000000000000000000000000000"
+ },
+ "src": "45134:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6641,
+ "nodeType": "ExpressionStatement",
+ "src": "45134:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6648,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6642,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45177:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6647,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6645,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6643,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45181:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6644,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "45185:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45181:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783834313032623030383933663634633730356538343164356434303634626433",
+ "id": 6646,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45195:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_175542044379434494067323265867529472979_by_1",
+ "typeString": "int_const 1755...(31 digits omitted)...2979"
+ },
+ "value": "0x84102b00893f64c705e841d5d4064bd3"
+ },
+ "src": "45181:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45177:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6649,
+ "nodeType": "ExpressionStatement",
+ "src": "45177:52:7"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6654,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6652,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45260:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783832303430353561616566316338626435633332353966343832323733356132",
+ "id": 6653,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45265:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_172820517236198538127967385733353125282_by_1",
+ "typeString": "int_const 1728...(31 digits omitted)...5282"
+ },
+ "value": "0x8204055aaef1c8bd5c3259f4822735a2"
+ },
+ "src": "45260:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6668,
+ "nodeType": "IfStatement",
+ "src": "45256:143:7",
+ "trueBody": {
+ "id": 6667,
+ "nodeType": "Block",
+ "src": "45301:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6657,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6655,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "45302:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783032303030303030303030303030303030303030303030303030303030303030",
+ "id": 6656,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45309:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2658455991569831745807614120560689152_by_1",
+ "typeString": "int_const 2658...(29 digits omitted)...9152"
+ },
+ "value": "0x02000000000000000000000000000000"
+ },
+ "src": "45302:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6658,
+ "nodeType": "ExpressionStatement",
+ "src": "45302:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6665,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6659,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45345:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6664,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6662,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6660,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45349:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6661,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "45353:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45349:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783832303430353561616566316338626435633332353966343832323733356132",
+ "id": 6663,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45363:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_172820517236198538127967385733353125282_by_1",
+ "typeString": "int_const 1728...(31 digits omitted)...5282"
+ },
+ "value": "0x8204055aaef1c8bd5c3259f4822735a2"
+ },
+ "src": "45349:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45345:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6666,
+ "nodeType": "ExpressionStatement",
+ "src": "45345:52:7"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6671,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6669,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45428:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783831303130306162303032323264383631393331633135653339623434653939",
+ "id": 6670,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45433:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_171475617301169790829459146906809945753_by_1",
+ "typeString": "int_const 1714...(31 digits omitted)...5753"
+ },
+ "value": "0x810100ab00222d861931c15e39b44e99"
+ },
+ "src": "45428:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6685,
+ "nodeType": "IfStatement",
+ "src": "45424:143:7",
+ "trueBody": {
+ "id": 6684,
+ "nodeType": "Block",
+ "src": "45469:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6674,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6672,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "45470:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783031303030303030303030303030303030303030303030303030303030303030",
+ "id": 6673,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45477:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1329227995784915872903807060280344576_by_1",
+ "typeString": "int_const 1329...(29 digits omitted)...4576"
+ },
+ "value": "0x01000000000000000000000000000000"
+ },
+ "src": "45470:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6675,
+ "nodeType": "ExpressionStatement",
+ "src": "45470:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6682,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6676,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45513:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6681,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6679,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6677,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45517:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6678,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "45521:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45517:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783831303130306162303032323264383631393331633135653339623434653939",
+ "id": 6680,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45531:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_171475617301169790829459146906809945753_by_1",
+ "typeString": "int_const 1714...(31 digits omitted)...5753"
+ },
+ "value": "0x810100ab00222d861931c15e39b44e99"
+ },
+ "src": "45517:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45513:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6683,
+ "nodeType": "ExpressionStatement",
+ "src": "45513:52:7"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6688,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6686,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45596:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783830383034303135356161626262653934353135323136393335353466373333",
+ "id": 6687,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45601:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_170807097224429000759274174605493073715_by_1",
+ "typeString": "int_const 1708...(31 digits omitted)...3715"
+ },
+ "value": "0x808040155aabbbe9451521693554f733"
+ },
+ "src": "45596:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6702,
+ "nodeType": "IfStatement",
+ "src": "45592:143:7",
+ "trueBody": {
+ "id": 6701,
+ "nodeType": "Block",
+ "src": "45637:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6691,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6689,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "45638:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783030383030303030303030303030303030303030303030303030303030303030",
+ "id": 6690,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45645:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_664613997892457936451903530140172288_by_1",
+ "typeString": "int_const 6646...(28 digits omitted)...2288"
+ },
+ "value": "0x00800000000000000000000000000000"
+ },
+ "src": "45638:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6692,
+ "nodeType": "ExpressionStatement",
+ "src": "45638:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6699,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6693,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45681:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6698,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6696,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6694,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45685:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6695,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "45689:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45685:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783830383034303135356161626262653934353135323136393335353466373333",
+ "id": 6697,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45699:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_170807097224429000759274174605493073715_by_1",
+ "typeString": "int_const 1708...(31 digits omitted)...3715"
+ },
+ "value": "0x808040155aabbbe9451521693554f733"
+ },
+ "src": "45685:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45681:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6700,
+ "nodeType": "ExpressionStatement",
+ "src": "45681:52:7"
+ }
+ ]
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6709,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6703,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "45762:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 6708,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6704,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "45766:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6707,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6705,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45770:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6706,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "45774:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45770:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45766:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45762:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6710,
+ "nodeType": "ExpressionStatement",
+ "src": "45762:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6717,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6711,
+ "name": "w",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6565,
+ "src": "45792:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6716,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6714,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6712,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "45796:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6713,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "45800:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45796:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6715,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "45804:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45796:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45792:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6718,
+ "nodeType": "ExpressionStatement",
+ "src": "45792:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6728,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6719,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "45822:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6727,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6725,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6720,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "45829:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6723,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078313030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6721,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45834:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_340282366920938463463374607431768211456_by_1",
+ "typeString": "int_const 3402...(31 digits omitted)...1456"
+ },
+ "value": "0x100000000000000000000000000000000"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6722,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "45872:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45834:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6724,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "45833:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45829:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078313030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6726,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45877:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_340282366920938463463374607431768211456_by_1",
+ "typeString": "int_const 3402...(31 digits omitted)...1456"
+ },
+ "value": "0x100000000000000000000000000000000"
+ },
+ "src": "45829:83:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45822:90:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6729,
+ "nodeType": "ExpressionStatement",
+ "src": "45822:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6736,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6730,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "45914:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6735,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6733,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6731,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "45918:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6732,
+ "name": "w",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6565,
+ "src": "45922:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45918:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6734,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "45926:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45918:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45914:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6737,
+ "nodeType": "ExpressionStatement",
+ "src": "45914:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6747,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6738,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "45973:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6746,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6744,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6739,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "45980:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6742,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078306161616161616161616161616161616161616161616161616161616161616161",
+ "id": 6740,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45985:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_226854911280625642308916404954512140970_by_1",
+ "typeString": "int_const 2268...(31 digits omitted)...0970"
+ },
+ "value": "0x0aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6741,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "46023:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45985:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6743,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "45984:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45980:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078323030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6745,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46028:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_680564733841876926926749214863536422912_by_1",
+ "typeString": "int_const 6805...(31 digits omitted)...2912"
+ },
+ "value": "0x200000000000000000000000000000000"
+ },
+ "src": "45980:83:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45973:90:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6748,
+ "nodeType": "ExpressionStatement",
+ "src": "45973:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6755,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6749,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46065:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6754,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6752,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6750,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46069:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6751,
+ "name": "w",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6565,
+ "src": "46073:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46069:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6753,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "46077:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46069:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46065:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6756,
+ "nodeType": "ExpressionStatement",
+ "src": "46065:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6766,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6757,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "46124:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6765,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6763,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6758,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46131:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6761,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303939393939393939393939393939393939393939393939393939393939393939",
+ "id": 6759,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46136:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_204169420152563078078024764459060926873_by_1",
+ "typeString": "int_const 2041...(31 digits omitted)...6873"
+ },
+ "value": "0x099999999999999999999999999999999"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6760,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "46174:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46136:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6762,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "46135:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46131:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078333030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6764,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46179:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1020847100762815390390123822295304634368_by_1",
+ "typeString": "int_const 1020...(32 digits omitted)...4368"
+ },
+ "value": "0x300000000000000000000000000000000"
+ },
+ "src": "46131:83:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46124:90:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6767,
+ "nodeType": "ExpressionStatement",
+ "src": "46124:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6774,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6768,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46216:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6773,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6771,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6769,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46220:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6770,
+ "name": "w",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6565,
+ "src": "46224:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46220:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6772,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "46228:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46220:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46216:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6775,
+ "nodeType": "ExpressionStatement",
+ "src": "46216:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6785,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6776,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "46275:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6784,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6782,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6777,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46282:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6780,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303932343932343932343932343932343932343932343932343932343932343932",
+ "id": 6778,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46287:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_194447066811964836264785489961010406546_by_1",
+ "typeString": "int_const 1944...(31 digits omitted)...6546"
+ },
+ "value": "0x092492492492492492492492492492492"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6779,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "46325:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46287:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6781,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "46286:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46282:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078343030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6783,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46330:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1361129467683753853853498429727072845824_by_1",
+ "typeString": "int_const 1361...(32 digits omitted)...5824"
+ },
+ "value": "0x400000000000000000000000000000000"
+ },
+ "src": "46282:83:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46275:90:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6786,
+ "nodeType": "ExpressionStatement",
+ "src": "46275:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6793,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6787,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46367:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6792,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6790,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6788,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46371:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6789,
+ "name": "w",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6565,
+ "src": "46375:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46371:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6791,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "46379:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46371:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46367:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6794,
+ "nodeType": "ExpressionStatement",
+ "src": "46367:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6804,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6795,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "46426:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6803,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6801,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6796,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46433:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6799,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303865333865333865333865333865333865333865333865333865333865333865",
+ "id": 6797,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46438:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_189045759400521368590763670795426784142_by_1",
+ "typeString": "int_const 1890...(31 digits omitted)...4142"
+ },
+ "value": "0x08e38e38e38e38e38e38e38e38e38e38e"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6798,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "46476:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46438:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6800,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "46437:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46433:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078353030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6802,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46481:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1701411834604692317316873037158841057280_by_1",
+ "typeString": "int_const 1701...(32 digits omitted)...7280"
+ },
+ "value": "0x500000000000000000000000000000000"
+ },
+ "src": "46433:83:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46426:90:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6805,
+ "nodeType": "ExpressionStatement",
+ "src": "46426:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6812,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6806,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46518:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6811,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6809,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6807,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46522:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6808,
+ "name": "w",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6565,
+ "src": "46526:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46522:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6810,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "46530:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46522:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46518:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6813,
+ "nodeType": "ExpressionStatement",
+ "src": "46518:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6823,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6814,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "46577:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6822,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6820,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6815,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46584:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6818,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303862613265386261326538626132653862613265386261326538626132653862",
+ "id": 6816,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46589:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_185608563775057343707295240417328115339_by_1",
+ "typeString": "int_const 1856...(31 digits omitted)...5339"
+ },
+ "value": "0x08ba2e8ba2e8ba2e8ba2e8ba2e8ba2e8b"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6817,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "46627:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46589:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6819,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "46588:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46584:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078363030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6821,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46632:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2041694201525630780780247644590609268736_by_1",
+ "typeString": "int_const 2041...(32 digits omitted)...8736"
+ },
+ "value": "0x600000000000000000000000000000000"
+ },
+ "src": "46584:83:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46577:90:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6824,
+ "nodeType": "ExpressionStatement",
+ "src": "46577:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6831,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6825,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46669:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6830,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6828,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6826,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46673:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6827,
+ "name": "w",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6565,
+ "src": "46677:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46673:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6829,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "46681:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46673:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46669:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6832,
+ "nodeType": "ExpressionStatement",
+ "src": "46669:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6842,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6833,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "46728:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6841,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6839,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6834,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46735:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6837,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303839643839643839643839643839643839643839643839643839643839643839",
+ "id": 6835,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46740:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_183228966803582249557201711694029036937_by_1",
+ "typeString": "int_const 1832...(31 digits omitted)...6937"
+ },
+ "value": "0x089d89d89d89d89d89d89d89d89d89d89"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6836,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "46778:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46740:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6838,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "46739:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46735:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078373030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6840,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46783:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2381976568446569244243622252022377480192_by_1",
+ "typeString": "int_const 2381...(32 digits omitted)...0192"
+ },
+ "value": "0x700000000000000000000000000000000"
+ },
+ "src": "46735:83:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46728:90:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6843,
+ "nodeType": "ExpressionStatement",
+ "src": "46728:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6850,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6844,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46820:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6849,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6847,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6845,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46824:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6846,
+ "name": "w",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6565,
+ "src": "46828:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46824:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6848,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "46832:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46824:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46820:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6851,
+ "nodeType": "ExpressionStatement",
+ "src": "46820:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6861,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6852,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "46879:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6860,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6858,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6853,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46886:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6856,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303838383838383838383838383838383838383838383838383838383838383838",
+ "id": 6854,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46891:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_181483929024500513847133123963609712776_by_1",
+ "typeString": "int_const 1814...(31 digits omitted)...2776"
+ },
+ "value": "0x088888888888888888888888888888888"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6855,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "46929:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46891:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6857,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "46890:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46886:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078383030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6859,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46934:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2722258935367507707706996859454145691648_by_1",
+ "typeString": "int_const 2722...(32 digits omitted)...1648"
+ },
+ "value": "0x800000000000000000000000000000000"
+ },
+ "src": "46886:83:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46879:90:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6862,
+ "nodeType": "ExpressionStatement",
+ "src": "46879:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6863,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "47039:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 6553,
+ "id": 6864,
+ "nodeType": "Return",
+ "src": "47032:10:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 6547,
+ "nodeType": "StructuredDocumentation",
+ "src": "43518:728:7",
+ "text": " @dev computes log(x / FIXED_1) * FIXED_1\n Input range: FIXED_1 <= x <= OPT_LOG_MAX_VAL - 1\n Auto-generated via 'PrintFunctionOptimalLog.py'\n Detailed description:\n - Rewrite the input as a product of natural exponents and a single residual r, such that 1 < r < 2\n - The natural logarithm of each (pre-calculated) exponent is the degree of the exponent\n - The natural logarithm of r is calculated via Taylor series for log(1 + x), where x = r - 1\n - The natural logarithm of the input is calculated by summing up the intermediate results above\n - For example: log(250) = log(e^4 * e^1 * e^0.5 * 1.021692859) = 4 + 1 + 0.5 + log(1 + 0.021692859)"
+ },
+ "id": 6866,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "optimalLog",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 6550,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 6549,
+ "mutability": "mutable",
+ "name": "x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6866,
+ "src": "44272:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6548,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "44272:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "44271:11:7"
+ },
+ "returnParameters": {
+ "id": 6553,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 6552,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6866,
+ "src": "44306:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6551,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "44306:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "44305:9:7"
+ },
+ "scope": 8977,
+ "src": "44252:2798:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 7275,
+ "nodeType": "Block",
+ "src": "47810:3153:7",
+ "statements": [
+ {
+ "assignments": [
+ 6875
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6875,
+ "mutability": "mutable",
+ "name": "res",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7275,
+ "src": "47821:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6874,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "47821:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6877,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 6876,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "47835:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "47821:15:7"
+ },
+ {
+ "assignments": [
+ 6879
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6879,
+ "mutability": "mutable",
+ "name": "y",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7275,
+ "src": "47849:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6878,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "47849:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6880,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "47849:9:7"
+ },
+ {
+ "assignments": [
+ 6882
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6882,
+ "mutability": "mutable",
+ "name": "z",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7275,
+ "src": "47869:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6881,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "47869:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6883,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "47869:9:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6890,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6884,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "47891:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 6889,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6885,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "47895:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6888,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6886,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6869,
+ "src": "47899:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "%",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783130303030303030303030303030303030303030303030303030303030303030",
+ "id": 6887,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "47903:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_21267647932558653966460912964485513216_by_1",
+ "typeString": "int_const 2126...(30 digits omitted)...3216"
+ },
+ "value": "0x10000000000000000000000000000000"
+ },
+ "src": "47899:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "47895:42:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "47891:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6891,
+ "nodeType": "ExpressionStatement",
+ "src": "47891:46:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6898,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6892,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "47979:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6897,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6895,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6893,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "47983:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6894,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "47987:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "47983:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6896,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "47991:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "47983:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "47979:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6899,
+ "nodeType": "ExpressionStatement",
+ "src": "47979:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6904,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6900,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48000:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6903,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6901,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48007:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307831306531623362653431356130303030",
+ "id": 6902,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48011:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1216451004088320000_by_1",
+ "typeString": "int_const 1216451004088320000"
+ },
+ "value": "0x10e1b3be415a0000"
+ },
+ "src": "48007:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48000:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6905,
+ "nodeType": "ExpressionStatement",
+ "src": "48000:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6912,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6906,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48066:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6911,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6909,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6907,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48070:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6908,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48074:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48070:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6910,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48078:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48070:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48066:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6913,
+ "nodeType": "ExpressionStatement",
+ "src": "48066:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6918,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6914,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48087:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6917,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6915,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48094:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830356130393133663662316530303030",
+ "id": 6916,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48098:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_405483668029440000_by_1",
+ "typeString": "int_const 405483668029440000"
+ },
+ "value": "0x05a0913f6b1e0000"
+ },
+ "src": "48094:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48087:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6919,
+ "nodeType": "ExpressionStatement",
+ "src": "48087:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6926,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6920,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48153:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6925,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6923,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6921,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48157:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6922,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48161:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48157:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6924,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48165:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48157:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48153:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6927,
+ "nodeType": "ExpressionStatement",
+ "src": "48153:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6932,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6928,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48174:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6931,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6929,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48181:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830313638323434666461633738303030",
+ "id": 6930,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48185:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_101370917007360000_by_1",
+ "typeString": "int_const 101370917007360000"
+ },
+ "value": "0x0168244fdac78000"
+ },
+ "src": "48181:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48174:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6933,
+ "nodeType": "ExpressionStatement",
+ "src": "48174:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6940,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6934,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48240:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6939,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6937,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6935,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48244:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6936,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48248:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48244:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6938,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48252:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48244:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48240:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6941,
+ "nodeType": "ExpressionStatement",
+ "src": "48240:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6946,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6942,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48261:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6945,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6943,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48268:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303438303734333262633138303030",
+ "id": 6944,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48272:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_20274183401472000_by_1",
+ "typeString": "int_const 20274183401472000"
+ },
+ "value": "0x004807432bc18000"
+ },
+ "src": "48268:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48261:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6947,
+ "nodeType": "ExpressionStatement",
+ "src": "48261:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6954,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6948,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48327:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6953,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6951,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6949,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48331:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6950,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48335:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48331:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6952,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48339:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48331:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48327:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6955,
+ "nodeType": "ExpressionStatement",
+ "src": "48327:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6960,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6956,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48348:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6959,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6957,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48355:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303063303133356463613034303030",
+ "id": 6958,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48359:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3379030566912000_by_1",
+ "typeString": "int_const 3379030566912000"
+ },
+ "value": "0x000c0135dca04000"
+ },
+ "src": "48355:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48348:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6961,
+ "nodeType": "ExpressionStatement",
+ "src": "48348:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6968,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6962,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48414:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6967,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6965,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6963,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48418:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6964,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48422:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48418:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6966,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48426:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48418:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48414:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6969,
+ "nodeType": "ExpressionStatement",
+ "src": "48414:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6974,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6970,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48435:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6973,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6971,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48442:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303031623730376231636463303030",
+ "id": 6972,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48446:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_482718652416000_by_1",
+ "typeString": "int_const 482718652416000"
+ },
+ "value": "0x0001b707b1cdc000"
+ },
+ "src": "48442:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48435:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6975,
+ "nodeType": "ExpressionStatement",
+ "src": "48435:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6982,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6976,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48501:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6981,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6979,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6977,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48505:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6978,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48509:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48505:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6980,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48513:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48505:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48501:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6983,
+ "nodeType": "ExpressionStatement",
+ "src": "48501:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6988,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6984,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48522:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6987,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6985,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48529:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030333665306636333962383030",
+ "id": 6986,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48533:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_60339831552000_by_1",
+ "typeString": "int_const 60339831552000"
+ },
+ "value": "0x000036e0f639b800"
+ },
+ "src": "48529:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48522:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6989,
+ "nodeType": "ExpressionStatement",
+ "src": "48522:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6996,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6990,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48588:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6995,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6993,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6991,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48592:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6992,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48596:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48592:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6994,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48600:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48592:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48588:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6997,
+ "nodeType": "ExpressionStatement",
+ "src": "48588:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7002,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6998,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48609:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7001,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6999,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48616:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303631386665653966383030",
+ "id": 7000,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48620:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6704425728000_by_1",
+ "typeString": "int_const 6704425728000"
+ },
+ "value": "0x00000618fee9f800"
+ },
+ "src": "48616:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48609:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7003,
+ "nodeType": "ExpressionStatement",
+ "src": "48609:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7010,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7004,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48675:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7009,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7007,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7005,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48679:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7006,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48683:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48679:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7008,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48687:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48679:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48675:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7011,
+ "nodeType": "ExpressionStatement",
+ "src": "48675:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7016,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7012,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48696:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7015,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7013,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48703:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303039633139376463633030",
+ "id": 7014,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48707:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_670442572800_by_1",
+ "typeString": "int_const 670442572800"
+ },
+ "value": "0x0000009c197dcc00"
+ },
+ "src": "48703:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48696:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7017,
+ "nodeType": "ExpressionStatement",
+ "src": "48696:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7024,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7018,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48762:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7023,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7021,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7019,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48766:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7020,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48770:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48766:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7022,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48774:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48766:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48762:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7025,
+ "nodeType": "ExpressionStatement",
+ "src": "48762:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7030,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7026,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48783:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7029,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7027,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48790:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030653330646365343030",
+ "id": 7028,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48794:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_60949324800_by_1",
+ "typeString": "int_const 60949324800"
+ },
+ "value": "0x0000000e30dce400"
+ },
+ "src": "48790:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48783:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7031,
+ "nodeType": "ExpressionStatement",
+ "src": "48783:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7038,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7032,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48849:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7037,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7035,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7033,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48853:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7034,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48857:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48853:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7036,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48861:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48853:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48849:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7039,
+ "nodeType": "ExpressionStatement",
+ "src": "48849:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7044,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7040,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48870:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7043,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7041,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48877:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030313265626431333030",
+ "id": 7042,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48881:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_5079110400_by_1",
+ "typeString": "int_const 5079110400"
+ },
+ "value": "0x000000012ebd1300"
+ },
+ "src": "48877:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48870:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7045,
+ "nodeType": "ExpressionStatement",
+ "src": "48870:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7052,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7046,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48936:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7051,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7049,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7047,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48940:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7048,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48944:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48940:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7050,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48948:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48940:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48936:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7053,
+ "nodeType": "ExpressionStatement",
+ "src": "48936:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7058,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7054,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48957:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7057,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7055,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48964:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303137343939663030",
+ "id": 7056,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48968:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_390700800_by_1",
+ "typeString": "int_const 390700800"
+ },
+ "value": "0x0000000017499f00"
+ },
+ "src": "48964:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48957:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7059,
+ "nodeType": "ExpressionStatement",
+ "src": "48957:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7066,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7060,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49023:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7065,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7063,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7061,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49027:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7062,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "49031:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49027:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7064,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "49035:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49027:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49023:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7067,
+ "nodeType": "ExpressionStatement",
+ "src": "49023:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7072,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7068,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49044:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7071,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7069,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49051:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303031613964343830",
+ "id": 7070,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49055:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_27907200_by_1",
+ "typeString": "int_const 27907200"
+ },
+ "value": "0x0000000001a9d480"
+ },
+ "src": "49051:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49044:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7073,
+ "nodeType": "ExpressionStatement",
+ "src": "49044:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7080,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7074,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49110:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7079,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7077,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7075,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49114:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7076,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "49118:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49114:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7078,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "49122:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49114:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49110:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7081,
+ "nodeType": "ExpressionStatement",
+ "src": "49110:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7086,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7082,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49131:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7085,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7083,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49138:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030316336333830",
+ "id": 7084,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49142:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1860480_by_1",
+ "typeString": "int_const 1860480"
+ },
+ "value": "0x00000000001c6380"
+ },
+ "src": "49138:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49131:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7087,
+ "nodeType": "ExpressionStatement",
+ "src": "49131:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7094,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7088,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49197:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7093,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7091,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7089,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49201:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7090,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "49205:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49201:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7092,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "49209:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49201:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49197:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7095,
+ "nodeType": "ExpressionStatement",
+ "src": "49197:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7100,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7096,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49218:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7099,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7097,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49225:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303163363338",
+ "id": 7098,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49229:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_116280_by_1",
+ "typeString": "int_const 116280"
+ },
+ "value": "0x000000000001c638"
+ },
+ "src": "49225:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49218:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7101,
+ "nodeType": "ExpressionStatement",
+ "src": "49218:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7108,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7102,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49284:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7107,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7105,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7103,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49288:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7104,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "49292:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49288:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7106,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "49296:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49288:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49284:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7109,
+ "nodeType": "ExpressionStatement",
+ "src": "49284:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7114,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7110,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49305:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7113,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7111,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49312:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303031616238",
+ "id": 7112,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49316:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6840_by_1",
+ "typeString": "int_const 6840"
+ },
+ "value": "0x0000000000001ab8"
+ },
+ "src": "49312:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49305:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7115,
+ "nodeType": "ExpressionStatement",
+ "src": "49305:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7122,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7116,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49371:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7121,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7119,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7117,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49375:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7118,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "49379:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49375:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7120,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "49383:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49375:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49371:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7123,
+ "nodeType": "ExpressionStatement",
+ "src": "49371:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7128,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7124,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49392:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7127,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7125,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49399:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030313763",
+ "id": 7126,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49403:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_380_by_1",
+ "typeString": "int_const 380"
+ },
+ "value": "0x000000000000017c"
+ },
+ "src": "49399:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49392:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7129,
+ "nodeType": "ExpressionStatement",
+ "src": "49392:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7136,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7130,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49458:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7135,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7133,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7131,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49462:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7132,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "49466:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49462:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7134,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "49470:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49462:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49458:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7137,
+ "nodeType": "ExpressionStatement",
+ "src": "49458:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7142,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7138,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49479:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7141,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7139,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49486:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303134",
+ "id": 7140,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49490:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_20_by_1",
+ "typeString": "int_const 20"
+ },
+ "value": "0x0000000000000014"
+ },
+ "src": "49486:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49479:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7143,
+ "nodeType": "ExpressionStatement",
+ "src": "49479:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7150,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7144,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49545:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7149,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7147,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7145,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49549:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7146,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "49553:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49549:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7148,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "49557:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49549:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49545:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7151,
+ "nodeType": "ExpressionStatement",
+ "src": "49545:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7156,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7152,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49566:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7155,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7153,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49573:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303031",
+ "id": 7154,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49577:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "0x0000000000000001"
+ },
+ "src": "49573:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49566:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7157,
+ "nodeType": "ExpressionStatement",
+ "src": "49566:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7166,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7158,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49632:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7165,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7163,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7161,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7159,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49638:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307832316333363737633832623430303030",
+ "id": 7160,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49644:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2432902008176640000_by_1",
+ "typeString": "int_const 2432902008176640000"
+ },
+ "value": "0x21c3677c82b40000"
+ },
+ "src": "49638:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7162,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "49665:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49638:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7164,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "49669:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49638:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49632:44:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7167,
+ "nodeType": "ExpressionStatement",
+ "src": "49632:44:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7173,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7170,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7168,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6869,
+ "src": "49744:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303130303030303030303030303030303030303030303030303030303030303030",
+ "id": 7169,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49748:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_21267647932558653966460912964485513216_by_1",
+ "typeString": "int_const 2126...(30 digits omitted)...3216"
+ },
+ "value": "0x010000000000000000000000000000000"
+ },
+ "src": "49744:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7171,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "49743:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 7172,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49788:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "49743:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7182,
+ "nodeType": "IfStatement",
+ "src": "49739:137:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7180,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7174,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49791:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7179,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7177,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7175,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49797:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078316333643661323465643832323138373837643632346433653565626139356639",
+ "id": 7176,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49803:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_600596269623765960634066700837880239609_by_1",
+ "typeString": "int_const 6005...(31 digits omitted)...9609"
+ },
+ "value": "0x1c3d6a24ed82218787d624d3e5eba95f9"
+ },
+ "src": "49797:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078313865626566396561633832306165383638326239373933616336643165373736",
+ "id": 7178,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49841:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_530024347646835984032474664511850276726_by_1",
+ "typeString": "int_const 5300...(31 digits omitted)...6726"
+ },
+ "value": "0x18ebef9eac820ae8682b9793ac6d1e776"
+ },
+ "src": "49797:79:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49791:85:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7181,
+ "nodeType": "ExpressionStatement",
+ "src": "49791:85:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7188,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7185,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7183,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6869,
+ "src": "49916:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303230303030303030303030303030303030303030303030303030303030303030",
+ "id": 7184,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49920:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_42535295865117307932921825928971026432_by_1",
+ "typeString": "int_const 4253...(30 digits omitted)...6432"
+ },
+ "value": "0x020000000000000000000000000000000"
+ },
+ "src": "49916:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7186,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "49915:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 7187,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49960:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "49915:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7197,
+ "nodeType": "IfStatement",
+ "src": "49911:137:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7195,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7189,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49963:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7194,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7192,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7190,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49969:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078313865626566396561633832306165383638326239373933616336643165373738",
+ "id": 7191,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49975:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_530024347646835984032474664511850276728_by_1",
+ "typeString": "int_const 5300...(31 digits omitted)...6728"
+ },
+ "value": "0x18ebef9eac820ae8682b9793ac6d1e778"
+ },
+ "src": "49969:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078313336386232666336663936303966653761636562343661613631396261656434",
+ "id": 7193,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50013:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_412783376994266390547521411024565284564_by_1",
+ "typeString": "int_const 4127...(31 digits omitted)...4564"
+ },
+ "value": "0x1368b2fc6f9609fe7aceb46aa619baed4"
+ },
+ "src": "49969:79:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49963:85:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7196,
+ "nodeType": "ExpressionStatement",
+ "src": "49963:85:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7203,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7200,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7198,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6869,
+ "src": "50088:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303430303030303030303030303030303030303030303030303030303030303030",
+ "id": 7199,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50092:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_85070591730234615865843651857942052864_by_1",
+ "typeString": "int_const 8507...(30 digits omitted)...2864"
+ },
+ "value": "0x040000000000000000000000000000000"
+ },
+ "src": "50088:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7201,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "50087:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 7202,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50132:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "50087:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7212,
+ "nodeType": "IfStatement",
+ "src": "50083:137:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7210,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7204,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50135:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7209,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7207,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7205,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50141:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078313336386232666336663936303966653761636562343661613631396261656435",
+ "id": 7206,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50147:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_412783376994266390547521411024565284565_by_1",
+ "typeString": "int_const 4127...(31 digits omitted)...4565"
+ },
+ "value": "0x1368b2fc6f9609fe7aceb46aa619baed5"
+ },
+ "src": "50141:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078306263356162316231363737396265333537356264386630353230613966323166",
+ "id": 7208,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50185:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_250365773966741064234501452596301656607_by_1",
+ "typeString": "int_const 2503...(31 digits omitted)...6607"
+ },
+ "value": "0x0bc5ab1b16779be3575bd8f0520a9f21f"
+ },
+ "src": "50141:79:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "50135:85:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7211,
+ "nodeType": "ExpressionStatement",
+ "src": "50135:85:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7218,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7215,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7213,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6869,
+ "src": "50260:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303830303030303030303030303030303030303030303030303030303030303030",
+ "id": 7214,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50264:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_170141183460469231731687303715884105728_by_1",
+ "typeString": "int_const 1701...(31 digits omitted)...5728"
+ },
+ "value": "0x080000000000000000000000000000000"
+ },
+ "src": "50260:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7216,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "50259:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 7217,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50304:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "50259:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7227,
+ "nodeType": "IfStatement",
+ "src": "50255:137:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7225,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7219,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50307:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7224,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7222,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7220,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50313:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078306263356162316231363737396265333537356264386630353230613966323165",
+ "id": 7221,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50319:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_250365773966741064234501452596301656606_by_1",
+ "typeString": "int_const 2503...(31 digits omitted)...6606"
+ },
+ "value": "0x0bc5ab1b16779be3575bd8f0520a9f21e"
+ },
+ "src": "50313:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303435346161613865666530373265376636646462616238346234306135356339",
+ "id": 7223,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50357:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_92104421015340344839251721785254237641_by_1",
+ "typeString": "int_const 9210...(30 digits omitted)...7641"
+ },
+ "value": "0x0454aaa8efe072e7f6ddbab84b40a55c9"
+ },
+ "src": "50313:79:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "50307:85:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7226,
+ "nodeType": "ExpressionStatement",
+ "src": "50307:85:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7233,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7230,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7228,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6869,
+ "src": "50432:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078313030303030303030303030303030303030303030303030303030303030303030",
+ "id": 7229,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50436:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_340282366920938463463374607431768211456_by_1",
+ "typeString": "int_const 3402...(31 digits omitted)...1456"
+ },
+ "value": "0x100000000000000000000000000000000"
+ },
+ "src": "50432:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7231,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "50431:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 7232,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50476:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "50431:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7242,
+ "nodeType": "IfStatement",
+ "src": "50427:137:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7240,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7234,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50479:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7239,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7237,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7235,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50485:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303435346161613865666530373265376636646462616238346234306135356335",
+ "id": 7236,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50491:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_92104421015340344839251721785254237637_by_1",
+ "typeString": "int_const 9210...(30 digits omitted)...7637"
+ },
+ "value": "0x0454aaa8efe072e7f6ddbab84b40a55c5"
+ },
+ "src": "50485:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303039363061616463313039653761336266343537383039393631353731316561",
+ "id": 7238,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50529:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_12464977905455307901915658421775307242_by_1",
+ "typeString": "int_const 1246...(30 digits omitted)...7242"
+ },
+ "value": "0x00960aadc109e7a3bf4578099615711ea"
+ },
+ "src": "50485:79:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "50479:85:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7241,
+ "nodeType": "ExpressionStatement",
+ "src": "50479:85:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7248,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7245,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7243,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6869,
+ "src": "50604:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078323030303030303030303030303030303030303030303030303030303030303030",
+ "id": 7244,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50608:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_680564733841876926926749214863536422912_by_1",
+ "typeString": "int_const 6805...(31 digits omitted)...2912"
+ },
+ "value": "0x200000000000000000000000000000000"
+ },
+ "src": "50604:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7246,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "50603:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 7247,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50648:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "50603:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7257,
+ "nodeType": "IfStatement",
+ "src": "50599:137:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7255,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7249,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50651:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7254,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7252,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7250,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50657:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303039363061616463313039653761336266343537383039393631353731316437",
+ "id": 7251,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50663:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_12464977905455307901915658421775307223_by_1",
+ "typeString": "int_const 1246...(30 digits omitted)...7223"
+ },
+ "value": "0x00960aadc109e7a3bf4578099615711d7"
+ },
+ "src": "50657:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030326266383432303832303466353937376639613863663031666463653364",
+ "id": 7253,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50701:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_228304034072369565894155946646425149_by_1",
+ "typeString": "int_const 2283...(28 digits omitted)...5149"
+ },
+ "value": "0x0002bf84208204f5977f9a8cf01fdce3d"
+ },
+ "src": "50657:79:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "50651:85:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7256,
+ "nodeType": "ExpressionStatement",
+ "src": "50651:85:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7263,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7260,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7258,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6869,
+ "src": "50776:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078343030303030303030303030303030303030303030303030303030303030303030",
+ "id": 7259,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50780:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1361129467683753853853498429727072845824_by_1",
+ "typeString": "int_const 1361...(32 digits omitted)...5824"
+ },
+ "value": "0x400000000000000000000000000000000"
+ },
+ "src": "50776:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7261,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "50775:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 7262,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50820:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "50775:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7272,
+ "nodeType": "IfStatement",
+ "src": "50771:137:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7270,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7264,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50823:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7269,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7267,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7265,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50829:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030326266383432303832303466353937376639613863663031666463333037",
+ "id": 7266,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50835:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_228304034072369565894155946646422279_by_1",
+ "typeString": "int_const 2283...(28 digits omitted)...2279"
+ },
+ "value": "0x0002bf84208204f5977f9a8cf01fdc307"
+ },
+ "src": "50829:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030336336616237373564643062393562346362656537653635643131",
+ "id": 7268,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50873:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_76587471230661696290698490699025_by_1",
+ "typeString": "int_const 76587471230661696290698490699025"
+ },
+ "value": "0x0000003c6ab775dd0b95b4cbee7e65d11"
+ },
+ "src": "50829:79:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "50823:85:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7271,
+ "nodeType": "ExpressionStatement",
+ "src": "50823:85:7"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7273,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50952:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 6873,
+ "id": 7274,
+ "nodeType": "Return",
+ "src": "50945:10:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 6867,
+ "nodeType": "StructuredDocumentation",
+ "src": "47058:683:7",
+ "text": " @dev computes e ^ (x / FIXED_1) * FIXED_1\n input range: 0 <= x <= OPT_EXP_MAX_VAL - 1\n auto-generated via 'PrintFunctionOptimalExp.py'\n Detailed description:\n - Rewrite the input as a sum of binary exponents and a single residual r, as small as possible\n - The exponentiation of each binary exponent is given (pre-calculated)\n - The exponentiation of r is calculated via Taylor series for e^x, where x = r\n - The exponentiation of the input is calculated by multiplying the intermediate results above\n - For example: e^5.521692859 = e^(4 + 1 + 0.5 + 0.021692859) = e^4 * e^1 * e^0.5 * e^0.021692859"
+ },
+ "id": 7276,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "optimalExp",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 6870,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 6869,
+ "mutability": "mutable",
+ "name": "x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7276,
+ "src": "47767:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6868,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "47767:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "47766:11:7"
+ },
+ "returnParameters": {
+ "id": 6873,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 6872,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7276,
+ "src": "47801:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6871,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "47801:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "47800:9:7"
+ },
+ "scope": 8977,
+ "src": "47747:3216:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 7312,
+ "nodeType": "Block",
+ "src": "51116:264:7",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7286,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7284,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7279,
+ "src": "51131:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7285,
+ "name": "LAMBERT_CONV_RADIUS",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3607,
+ "src": "51137:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "51131:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7291,
+ "nodeType": "IfStatement",
+ "src": "51127:66:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 7288,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7279,
+ "src": "51190:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 7287,
+ "name": "lambertPos1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7842,
+ "src": "51178:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 7289,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "51178:15:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7283,
+ "id": 7290,
+ "nodeType": "Return",
+ "src": "51171:22:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7294,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7292,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7279,
+ "src": "51208:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7293,
+ "name": "LAMBERT_POS2_MAXVAL",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3613,
+ "src": "51214:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "51208:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7299,
+ "nodeType": "IfStatement",
+ "src": "51204:66:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 7296,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7279,
+ "src": "51267:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 7295,
+ "name": "lambertPos2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7911,
+ "src": "51255:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) view returns (uint256)"
+ }
+ },
+ "id": 7297,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "51255:15:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7283,
+ "id": 7298,
+ "nodeType": "Return",
+ "src": "51248:22:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7302,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7300,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7279,
+ "src": "51285:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7301,
+ "name": "LAMBERT_POS3_MAXVAL",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3616,
+ "src": "51291:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "51285:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7307,
+ "nodeType": "IfStatement",
+ "src": "51281:66:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 7304,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7279,
+ "src": "51344:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 7303,
+ "name": "lambertPos3",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7961,
+ "src": "51332:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 7305,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "51332:15:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7283,
+ "id": 7306,
+ "nodeType": "Return",
+ "src": "51325:22:7"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "66616c7365",
+ "id": 7309,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "51366:5:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "false"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ ],
+ "id": 7308,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "51358:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
+ "typeString": "function (bool) pure"
+ }
+ },
+ "id": 7310,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "51358:14:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 7311,
+ "nodeType": "ExpressionStatement",
+ "src": "51358:14:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 7277,
+ "nodeType": "StructuredDocumentation",
+ "src": "50971:75:7",
+ "text": " @dev computes W(x / FIXED_1) / (x / FIXED_1) * FIXED_1"
+ },
+ "id": 7313,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "lowerStake",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 7280,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7279,
+ "mutability": "mutable",
+ "name": "_x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7313,
+ "src": "51072:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7278,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "51072:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "51071:12:7"
+ },
+ "returnParameters": {
+ "id": 7283,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7282,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7313,
+ "src": "51107:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7281,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "51107:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "51106:9:7"
+ },
+ "scope": 8977,
+ "src": "51052:328:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 7335,
+ "nodeType": "Block",
+ "src": "51536:125:7",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7323,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7321,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7316,
+ "src": "51551:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7322,
+ "name": "LAMBERT_CONV_RADIUS",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3607,
+ "src": "51557:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "51551:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7328,
+ "nodeType": "IfStatement",
+ "src": "51547:66:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 7325,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7316,
+ "src": "51610:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 7324,
+ "name": "lambertNeg1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8466,
+ "src": "51598:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 7326,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "51598:15:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7320,
+ "id": 7327,
+ "nodeType": "Return",
+ "src": "51591:22:7"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7333,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7331,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7329,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "51631:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7330,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "51641:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "51631:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7332,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7316,
+ "src": "51651:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "51631:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7320,
+ "id": 7334,
+ "nodeType": "Return",
+ "src": "51624:29:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 7314,
+ "nodeType": "StructuredDocumentation",
+ "src": "51388:77:7",
+ "text": " @dev computes W(-x / FIXED_1) / (-x / FIXED_1) * FIXED_1"
+ },
+ "id": 7336,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "higherStake",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 7317,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7316,
+ "mutability": "mutable",
+ "name": "_x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7336,
+ "src": "51492:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7315,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "51492:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "51491:12:7"
+ },
+ "returnParameters": {
+ "id": 7320,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7319,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7336,
+ "src": "51527:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7318,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "51527:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "51526:9:7"
+ },
+ "scope": 8977,
+ "src": "51471:190:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 7841,
+ "nodeType": "Block",
+ "src": "51921:4576:7",
+ "statements": [
+ {
+ "assignments": [
+ 7345
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7345,
+ "mutability": "mutable",
+ "name": "xi",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7841,
+ "src": "51932:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7344,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "51932:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7347,
+ "initialValue": {
+ "argumentTypes": null,
+ "id": 7346,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "51945:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "51932:15:7"
+ },
+ {
+ "assignments": [
+ 7349
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7349,
+ "mutability": "mutable",
+ "name": "res",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7841,
+ "src": "51958:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7348,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "51958:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7356,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7355,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7352,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7350,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "51973:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7351,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "51983:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "51973:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7353,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "51972:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30786465316263346431396566636163383234343564613735623030303030303030",
+ "id": 7354,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "51989:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_295232799039604140847618609643520000000_by_1",
+ "typeString": "int_const 2952...(31 digits omitted)...0000"
+ },
+ "value": "0xde1bc4d19efcac82445da75b00000000"
+ },
+ "src": "51972:51:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "51958:65:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7364,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7357,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52103:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7363,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7360,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7358,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52109:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7359,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "52114:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52109:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7361,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "52108:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7362,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "52120:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52108:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52103:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7365,
+ "nodeType": "ExpressionStatement",
+ "src": "52103:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7370,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7366,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "52129:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7369,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7367,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52136:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303030313464323961373361366537623032633336363863376230383830303030303030",
+ "id": 7368,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "52141:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_442849198559406211271427914465280000000_by_1",
+ "typeString": "int_const 4428...(31 digits omitted)...0000"
+ },
+ "value": "0x00000000014d29a73a6e7b02c3668c7b0880000000"
+ },
+ "src": "52136:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52129:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7371,
+ "nodeType": "ExpressionStatement",
+ "src": "52129:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7379,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7372,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52238:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7378,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7375,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7373,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52244:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7374,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "52249:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52244:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7376,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "52243:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7377,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "52255:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52243:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52238:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7380,
+ "nodeType": "ExpressionStatement",
+ "src": "52238:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7385,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7381,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "52264:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7384,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7382,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52271:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303030323530346130636439613766373231356236306639626534383030303030303030",
+ "id": 7383,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "52276:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_787287464105611042260316292382720000000_by_1",
+ "typeString": "int_const 7872...(31 digits omitted)...0000"
+ },
+ "value": "0x0000000002504a0cd9a7f7215b60f9be4800000000"
+ },
+ "src": "52271:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52264:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7386,
+ "nodeType": "ExpressionStatement",
+ "src": "52264:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7394,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7387,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52373:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7393,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7390,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7388,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52379:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7389,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "52384:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52379:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7391,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "52378:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7392,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "52390:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52378:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52373:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7395,
+ "nodeType": "ExpressionStatement",
+ "src": "52373:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7400,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7396,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "52399:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7399,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7397,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52406:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303030343834643061313139316330656164323637393637633761346130303030303030",
+ "id": 7398,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "52411:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1537670828331271566914680258560000000000_by_1",
+ "typeString": "int_const 1537...(32 digits omitted)...0000"
+ },
+ "value": "0x000000000484d0a1191c0ead267967c7a4a0000000"
+ },
+ "src": "52406:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52399:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7401,
+ "nodeType": "ExpressionStatement",
+ "src": "52399:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7409,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7402,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52508:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7408,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7405,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7403,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52514:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7404,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "52519:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52514:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7406,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "52513:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7407,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "52525:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52513:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52508:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7410,
+ "nodeType": "ExpressionStatement",
+ "src": "52508:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7415,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7411,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "52534:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7414,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7412,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52541:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303030393565633538306437653834323761346261663236613930613030303030303030",
+ "id": 7413,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "52546:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3188514229627724721154280984150016000000_by_1",
+ "typeString": "int_const 3188...(32 digits omitted)...0000"
+ },
+ "value": "0x00000000095ec580d7e8427a4baf26a90a00000000"
+ },
+ "src": "52541:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52534:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7416,
+ "nodeType": "ExpressionStatement",
+ "src": "52534:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7424,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7417,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52643:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7423,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7420,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7418,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52649:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7419,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "52654:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52649:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7421,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "52648:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7422,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "52660:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52648:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52643:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7425,
+ "nodeType": "ExpressionStatement",
+ "src": "52643:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7430,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7426,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "52669:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7429,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7427,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52676:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303031343430623062653136313561343764626136653562336231663130303030303030",
+ "id": 7428,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "52681:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6891635629803648326702674961498112000000_by_1",
+ "typeString": "int_const 6891...(32 digits omitted)...0000"
+ },
+ "value": "0x000000001440b0be1615a47dba6e5b3b1f10000000"
+ },
+ "src": "52676:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52669:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7431,
+ "nodeType": "ExpressionStatement",
+ "src": "52669:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7439,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7432,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52778:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7438,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7435,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7433,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52784:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7434,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "52789:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52784:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7436,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "52783:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7437,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "52795:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52783:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52778:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7440,
+ "nodeType": "ExpressionStatement",
+ "src": "52778:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7445,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7441,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "52804:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7444,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7442,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52811:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303032643230373630316634366139396234313132343138343030303030303030303030",
+ "id": 7443,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "52816:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_15355854537983727757610740636188672000000_by_1",
+ "typeString": "int_const 1535...(33 digits omitted)...0000"
+ },
+ "value": "0x000000002d207601f46a99b4112418400000000000"
+ },
+ "src": "52811:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52804:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7446,
+ "nodeType": "ExpressionStatement",
+ "src": "52804:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7454,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7447,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52913:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7453,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7450,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7448,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52919:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7449,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "52924:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52919:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7451,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "52918:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7452,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "52930:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52918:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52913:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7455,
+ "nodeType": "ExpressionStatement",
+ "src": "52913:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7460,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7456,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "52939:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7459,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7457,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52946:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303036366562616163346333376336323264643832383861376562316232303030303030",
+ "id": 7458,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "52951:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_35022056686251398262544482483830784000000_by_1",
+ "typeString": "int_const 3502...(33 digits omitted)...0000"
+ },
+ "value": "0x0000000066ebaac4c37c622dd8288a7eb1b2000000"
+ },
+ "src": "52946:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52939:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7461,
+ "nodeType": "ExpressionStatement",
+ "src": "52939:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7469,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7462,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53048:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7468,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7465,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7463,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53054:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7464,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "53059:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53054:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7466,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "53053:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7467,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "53065:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53053:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53048:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7470,
+ "nodeType": "ExpressionStatement",
+ "src": "53048:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7475,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7471,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "53074:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7474,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7472,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53081:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303065663137323430313335663764626434336131626131306366323030303030303030",
+ "id": 7473,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "53086:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_81358244885252463857919590400000000000000_by_1",
+ "typeString": "int_const 8135...(33 digits omitted)...0000"
+ },
+ "value": "0x00000000ef17240135f7dbd43a1ba10cf200000000"
+ },
+ "src": "53081:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53074:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7476,
+ "nodeType": "ExpressionStatement",
+ "src": "53074:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7484,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7477,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53183:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7483,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7480,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7478,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53189:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7479,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "53194:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53189:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7481,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "53188:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7482,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "53200:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53188:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53183:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7485,
+ "nodeType": "ExpressionStatement",
+ "src": "53183:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7490,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7486,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "53209:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7489,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7487,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53216:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303233336333336336373661356562323431363039346138376233363537303030303030",
+ "id": 7488,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "53221:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_191838485670993607105842450247345766400000_by_1",
+ "typeString": "int_const 1918...(34 digits omitted)...0000"
+ },
+ "value": "0x0000000233c33c676a5eb2416094a87b3657000000"
+ },
+ "src": "53216:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53209:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7491,
+ "nodeType": "ExpressionStatement",
+ "src": "53209:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7499,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7492,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53318:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7498,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7495,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7493,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53324:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7494,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "53329:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53324:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7496,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "53323:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7497,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "53335:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53323:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53318:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7500,
+ "nodeType": "ExpressionStatement",
+ "src": "53318:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7505,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7501,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "53344:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7504,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7502,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53351:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303534316364653438626330323534626564343961396638373030303030303030303030",
+ "id": 7503,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "53356:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_457953461925960171898563951427426713600000_by_1",
+ "typeString": "int_const 4579...(34 digits omitted)...0000"
+ },
+ "value": "0x0000000541cde48bc0254bed49a9f8700000000000"
+ },
+ "src": "53351:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53344:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7506,
+ "nodeType": "ExpressionStatement",
+ "src": "53344:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7514,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7507,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53453:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7513,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7510,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7508,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53459:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7509,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "53464:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53459:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7511,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "53458:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7512,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "53470:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53458:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53453:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7515,
+ "nodeType": "ExpressionStatement",
+ "src": "53453:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7520,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7516,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "53479:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7519,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7517,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53486:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030306361653166616432636464346434636238643733616263613064313961343030303030",
+ "id": 7518,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "53491:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1104598668270551480892683896320648806400000_by_1",
+ "typeString": "int_const 1104...(35 digits omitted)...0000"
+ },
+ "value": "0x0000000cae1fad2cdd4d4cb8d73abca0d19a400000"
+ },
+ "src": "53486:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53479:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7521,
+ "nodeType": "ExpressionStatement",
+ "src": "53479:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7529,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7522,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53588:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7528,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7525,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7523,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53594:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7524,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "53599:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53594:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7526,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "53593:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7527,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "53605:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53593:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53588:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7530,
+ "nodeType": "ExpressionStatement",
+ "src": "53588:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7535,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7531,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "53614:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7534,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7532,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53621:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030316564623261613266373630643135633431636565646261393536343030303030303030",
+ "id": 7533,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "53626:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2687947090053832841608264823563773542400000_by_1",
+ "typeString": "int_const 2687...(35 digits omitted)...0000"
+ },
+ "value": "0x0000001edb2aa2f760d15c41ceedba956400000000"
+ },
+ "src": "53621:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53614:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7536,
+ "nodeType": "ExpressionStatement",
+ "src": "53614:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7544,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7537,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53723:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7543,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7540,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7538,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53729:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7539,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "53734:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53729:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7541,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "53728:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7542,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "53740:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53728:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53723:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7545,
+ "nodeType": "ExpressionStatement",
+ "src": "53723:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7550,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7546,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "53749:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7549,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7547,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53756:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030346261386432306432646162643338366339353239363539383431613265323030303030",
+ "id": 7548,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "53761:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6590868088830032065882824000000000000000000_by_1",
+ "typeString": "int_const 6590...(35 digits omitted)...0000"
+ },
+ "value": "0x0000004ba8d20d2dabd386c9529659841a2e200000"
+ },
+ "src": "53756:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53749:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7551,
+ "nodeType": "ExpressionStatement",
+ "src": "53749:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7559,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7552,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53858:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7558,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7555,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7553,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53864:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7554,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "53869:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53864:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7556,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "53863:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7557,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "53875:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53863:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53858:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7560,
+ "nodeType": "ExpressionStatement",
+ "src": "53858:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7565,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7561,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "53884:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7564,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7562,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53891:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030626163303835343662383637636461613230303030303030303030303030303030303030",
+ "id": 7563,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "53896:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_16268396552280633070412438458028041175040000_by_1",
+ "typeString": "int_const 1626...(36 digits omitted)...0000"
+ },
+ "value": "0x000000bac08546b867cdaa20000000000000000000"
+ },
+ "src": "53891:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53884:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7566,
+ "nodeType": "ExpressionStatement",
+ "src": "53884:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7574,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7567,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53993:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7573,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7570,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7568,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53999:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7569,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "54004:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53999:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7571,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "53998:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7572,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "54010:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53998:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53993:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7575,
+ "nodeType": "ExpressionStatement",
+ "src": "53993:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7580,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7576,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "54019:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7579,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7577,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54026:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303031636661386537306330333632356239646237366338656266356262663234383230303030",
+ "id": 7578,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "54031:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_40390462938090940419774080664538139934720000_by_1",
+ "typeString": "int_const 4039...(36 digits omitted)...0000"
+ },
+ "value": "0x000001cfa8e70c03625b9db76c8ebf5bbf24820000"
+ },
+ "src": "54026:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54019:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7581,
+ "nodeType": "ExpressionStatement",
+ "src": "54019:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7589,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7582,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54128:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7588,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7585,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7583,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54134:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7584,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "54139:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54134:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7586,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "54133:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7587,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "54145:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54133:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54128:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7590,
+ "nodeType": "ExpressionStatement",
+ "src": "54128:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7595,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7591,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "54154:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7594,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7592,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54161:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303034383531643939663832303630646632363566333330396232366638323030303030303030",
+ "id": 7593,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "54166:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_100798987671917000666814256179934522245120000_by_1",
+ "typeString": "int_const 1007...(37 digits omitted)...0000"
+ },
+ "value": "0x000004851d99f82060df265f3309b26f8200000000"
+ },
+ "src": "54161:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54154:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7596,
+ "nodeType": "ExpressionStatement",
+ "src": "54154:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7604,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7597,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54263:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7603,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7600,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7598,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54269:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7599,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "54274:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54269:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7601,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "54268:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7602,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "54280:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54268:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54263:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7605,
+ "nodeType": "ExpressionStatement",
+ "src": "54263:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7610,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7606,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "54289:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7609,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7607,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54296:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303062353530643139623132396432373063343466366635356630323737323363626230303030",
+ "id": 7608,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "54301:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_252717199309391137912965664538441463029760000_by_1",
+ "typeString": "int_const 2527...(37 digits omitted)...0000"
+ },
+ "value": "0x00000b550d19b129d270c44f6f55f027723cbb0000"
+ },
+ "src": "54296:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54289:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7611,
+ "nodeType": "ExpressionStatement",
+ "src": "54289:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7619,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7612,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54398:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7618,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7615,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7613,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54404:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7614,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "54409:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54404:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7616,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "54403:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7617,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "54415:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54403:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54398:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7620,
+ "nodeType": "ExpressionStatement",
+ "src": "54398:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7625,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7621,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "54424:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7624,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7622,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54431:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303163383737646164633736316463323732646562363564346230303030303030303030303030",
+ "id": 7623,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "54436:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_636223790447205380259840000000000000000000000_by_1",
+ "typeString": "int_const 6362...(37 digits omitted)...0000"
+ },
+ "value": "0x00001c877dadc761dc272deb65d4b0000000000000"
+ },
+ "src": "54431:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54424:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7626,
+ "nodeType": "ExpressionStatement",
+ "src": "54424:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7634,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7627,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54533:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7633,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7630,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7628,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54539:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7629,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "54544:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54539:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7631,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "54538:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7632,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "54550:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54538:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54533:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7635,
+ "nodeType": "ExpressionStatement",
+ "src": "54533:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7640,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7636,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "54559:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7639,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7637,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54566:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303438313738656365393734373966333361373766326164323261383162363434303663303030",
+ "id": 7638,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "54571:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1607705831573194746802610334450509017233408000_by_1",
+ "typeString": "int_const 1607...(38 digits omitted)...8000"
+ },
+ "value": "0x000048178ece97479f33a77f2ad22a81b64406c000"
+ },
+ "src": "54566:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54559:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7641,
+ "nodeType": "ExpressionStatement",
+ "src": "54559:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7649,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7642,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54668:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7648,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7645,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7643,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54674:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7644,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "54679:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54674:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7646,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "54673:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7647,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "54685:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54673:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54668:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7650,
+ "nodeType": "ExpressionStatement",
+ "src": "54668:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7655,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7651,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "54694:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7654,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7652,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54701:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030306236636138323638623964383130666564663636393565663266386136633030303030303030",
+ "id": 7653,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "54706:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4076376683803157531046819273912505658769408000_by_1",
+ "typeString": "int_const 4076...(38 digits omitted)...8000"
+ },
+ "value": "0x0000b6ca8268b9d810fedf6695ef2f8a6c00000000"
+ },
+ "src": "54701:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54694:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7656,
+ "nodeType": "ExpressionStatement",
+ "src": "54694:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7664,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7657,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54803:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7663,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7660,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7658,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54809:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7659,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "54814:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54809:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7661,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "54808:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7662,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "54820:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54808:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54803:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7665,
+ "nodeType": "ExpressionStatement",
+ "src": "54803:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7670,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7666,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "54829:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7669,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7667,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54836:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030316430653736363331613562303564303037623863623732613763376631316563333665303030",
+ "id": 7668,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "54841:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_10367703484962349537949059901011799777283072000_by_1",
+ "typeString": "int_const 1036...(39 digits omitted)...2000"
+ },
+ "value": "0x0001d0e76631a5b05d007b8cb72a7c7f11ec36e000"
+ },
+ "src": "54836:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54829:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7671,
+ "nodeType": "ExpressionStatement",
+ "src": "54829:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7679,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7672,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54938:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7678,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7675,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7673,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54944:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7674,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "54949:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54944:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7676,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "54943:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7677,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "54955:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54943:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54938:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7680,
+ "nodeType": "ExpressionStatement",
+ "src": "54938:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7685,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7681,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "54964:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7684,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7682,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54971:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030346131633337626439663835666439633663373830303030303030303030303030303030303030",
+ "id": 7683,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "54976:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_26443412100478721735433130630260686447443968000_by_1",
+ "typeString": "int_const 2644...(39 digits omitted)...8000"
+ },
+ "value": "0x0004a1c37bd9f85fd9c6c780000000000000000000"
+ },
+ "src": "54971:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54964:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7686,
+ "nodeType": "ExpressionStatement",
+ "src": "54964:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7694,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7687,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55073:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7693,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7690,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7688,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55079:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7689,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "55084:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55079:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7691,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "55078:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7692,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "55090:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55078:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55073:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7695,
+ "nodeType": "ExpressionStatement",
+ "src": "55073:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7700,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7696,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "55099:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7699,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7697,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55106:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030626438333639663162373032626634393165326562666365653038323530333133623635343030",
+ "id": 7698,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "55111:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_67620617646753089502453804016113281250000000000_by_1",
+ "typeString": "int_const 6762...(39 digits omitted)...0000"
+ },
+ "value": "0x000bd8369f1b702bf491e2ebfcee08250313b65400"
+ },
+ "src": "55106:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55099:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7701,
+ "nodeType": "ExpressionStatement",
+ "src": "55099:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7709,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7702,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55208:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7708,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7705,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7703,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55214:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7704,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "55219:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55214:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7706,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "55213:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7707,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "55225:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55213:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55208:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7710,
+ "nodeType": "ExpressionStatement",
+ "src": "55208:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7715,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7711,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "55234:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7714,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7712,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55241:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303031653563376333326139663663373061623263623539643932323537363464343030303030303030",
+ "id": 7713,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "55246:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_173332210846474760735500226875327576716638945280_by_1",
+ "typeString": "int_const 1733...(40 digits omitted)...5280"
+ },
+ "value": "0x001e5c7c32a9f6c70ab2cb59d9225764d400000000"
+ },
+ "src": "55241:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55234:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7716,
+ "nodeType": "ExpressionStatement",
+ "src": "55234:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7724,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7717,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55343:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7723,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7720,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7718,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55349:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7719,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "55354:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55349:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7721,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "55348:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7722,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "55360:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55348:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55343:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7725,
+ "nodeType": "ExpressionStatement",
+ "src": "55343:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7730,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7726,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "55369:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7729,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7727,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55376:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303034646666353832306531363565393130663935313230613730386537343234393632323165363030",
+ "id": 7728,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "55381:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_445286656448864136819345605176268818347976680960_by_1",
+ "typeString": "int_const 4452...(40 digits omitted)...0960"
+ },
+ "value": "0x004dff5820e165e910f95120a708e742496221e600"
+ },
+ "src": "55376:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55369:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7731,
+ "nodeType": "ExpressionStatement",
+ "src": "55369:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7739,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7732,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55478:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7738,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7735,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7733,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55484:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7734,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "55489:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55484:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7736,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "55483:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7737,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "55495:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55483:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55478:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7740,
+ "nodeType": "ExpressionStatement",
+ "src": "55478:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7745,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7741,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "55504:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7744,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7742,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55511:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303063386338663636646231666365643337386565353065353336303030303030303030303030303030",
+ "id": 7743,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "55516:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1146279770154177862273033179056478989553563074560_by_1",
+ "typeString": "int_const 1146...(41 digits omitted)...4560"
+ },
+ "value": "0x00c8c8f66db1fced378ee50e536000000000000000"
+ },
+ "src": "55511:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55504:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7746,
+ "nodeType": "ExpressionStatement",
+ "src": "55504:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7754,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7747,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55613:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7753,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7750,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7748,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55619:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7749,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "55624:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55619:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7751,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "55618:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7752,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "55630:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55618:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55613:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7755,
+ "nodeType": "ExpressionStatement",
+ "src": "55613:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7760,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7756,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "55639:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7759,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7757,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55646:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303230356462386466666666343562666132393338663132386635393964626631366562313164383830",
+ "id": 7758,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "55651:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2956444461658038477759873400213214992927382689920_by_1",
+ "typeString": "int_const 2956...(41 digits omitted)...9920"
+ },
+ "value": "0x0205db8dffff45bfa2938f128f599dbf16eb11d880"
+ },
+ "src": "55646:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55639:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7761,
+ "nodeType": "ExpressionStatement",
+ "src": "55639:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7769,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7762,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55748:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7768,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7765,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7763,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55754:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7764,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "55759:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55754:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7766,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "55753:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7767,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "55765:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55753:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55748:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7770,
+ "nodeType": "ExpressionStatement",
+ "src": "55748:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7775,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7771,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "55774:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7774,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7772,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55781:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303533613034346562643938343335313439336531373836616633386433396130383030303030303030",
+ "id": 7773,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "55786:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_7638725713617153619200000000000000000000000000000_by_1",
+ "typeString": "int_const 7638...(41 digits omitted)...0000"
+ },
+ "value": "0x053a044ebd984351493e1786af38d39a0800000000"
+ },
+ "src": "55781:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55774:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7776,
+ "nodeType": "ExpressionStatement",
+ "src": "55774:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7784,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7777,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55883:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7783,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7780,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7778,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55889:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7779,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "55894:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55889:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7781,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "55888:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7782,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "55900:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55888:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55883:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7785,
+ "nodeType": "ExpressionStatement",
+ "src": "55883:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7790,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7786,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "55909:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7789,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7787,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55916:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078306438366461653261346363306634373633336135343434373937333538363962343837623539633430",
+ "id": 7788,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "55921:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_19769407354499582705095371848882117322613875645504_by_1",
+ "typeString": "int_const 1976...(42 digits omitted)...5504"
+ },
+ "value": "0x0d86dae2a4cc0f47633a544479735869b487b59c40"
+ },
+ "src": "55916:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55909:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7791,
+ "nodeType": "ExpressionStatement",
+ "src": "55909:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7799,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7792,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56018:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7798,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7795,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7793,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56024:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7794,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "56029:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56024:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7796,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "56023:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7797,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "56035:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56023:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56018:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7800,
+ "nodeType": "ExpressionStatement",
+ "src": "56018:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7805,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7801,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "56044:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7804,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7802,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56051:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078323331303030303030303030303030303030303030303030303030303030303030303030303030303030",
+ "id": 7803,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "56056:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_51243901158914783569516699447114673376686134788096_by_1",
+ "typeString": "int_const 5124...(42 digits omitted)...8096"
+ },
+ "value": "0x231000000000000000000000000000000000000000"
+ },
+ "src": "56051:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56044:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7806,
+ "nodeType": "ExpressionStatement",
+ "src": "56044:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7814,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7807,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56153:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7813,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7810,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7808,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56159:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7809,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "56164:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56159:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7811,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "56158:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7812,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "56170:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56158:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56153:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7815,
+ "nodeType": "ExpressionStatement",
+ "src": "56153:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7820,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7816,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "56179:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7819,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7817,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56186:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078356230343835613736663636343663323033396462313530376364643531623038363439363830383232",
+ "id": 7818,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "56191:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_133022465544965907471119545993290733585983764695074_by_1",
+ "typeString": "int_const 1330...(43 digits omitted)...5074"
+ },
+ "value": "0x5b0485a76f6646c2039db1507cdd51b08649680822"
+ },
+ "src": "56186:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56179:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7821,
+ "nodeType": "ExpressionStatement",
+ "src": "56179:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7829,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7822,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56288:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7828,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7825,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7823,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56294:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7824,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "56299:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56294:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7826,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "56293:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7827,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "56305:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56293:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56288:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7830,
+ "nodeType": "ExpressionStatement",
+ "src": "56288:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7835,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7831,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "56314:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7834,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7832,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56321:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078656339383363343663343935343562633137656661366235623030353565323432323030303030303030",
+ "id": 7833,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "56326:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_345783497216724000335707367685598692782880644399104_by_1",
+ "typeString": "int_const 3457...(43 digits omitted)...9104"
+ },
+ "value": "0xec983c46c49545bc17efa6b5b0055e242200000000"
+ },
+ "src": "56321:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56314:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7836,
+ "nodeType": "ExpressionStatement",
+ "src": "56314:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7839,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7837,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "56432:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30786465316263346431396566636163383234343564613735623030303030303030",
+ "id": 7838,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "56438:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_295232799039604140847618609643520000000_by_1",
+ "typeString": "int_const 2952...(31 digits omitted)...0000"
+ },
+ "value": "0xde1bc4d19efcac82445da75b00000000"
+ },
+ "src": "56432:40:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7343,
+ "id": 7840,
+ "nodeType": "Return",
+ "src": "56425:47:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 7337,
+ "nodeType": "StructuredDocumentation",
+ "src": "51669:181:7",
+ "text": " @dev computes W(x / FIXED_1) / (x / FIXED_1) * FIXED_1\n input range: 1 <= x <= 1 / e * FIXED_1\n auto-generated via 'PrintFunctionLambertPos1.py'"
+ },
+ "id": 7842,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "lambertPos1",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 7340,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7339,
+ "mutability": "mutable",
+ "name": "_x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7842,
+ "src": "51877:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7338,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "51877:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "51876:12:7"
+ },
+ "returnParameters": {
+ "id": 7343,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7342,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7842,
+ "src": "51912:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7341,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "51912:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "51911:9:7"
+ },
+ "scope": 8977,
+ "src": "51856:4641:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 7910,
+ "nodeType": "Block",
+ "src": "56725:350:7",
+ "statements": [
+ {
+ "assignments": [
+ 7851
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7851,
+ "mutability": "mutable",
+ "name": "x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7910,
+ "src": "56736:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7850,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "56736:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7857,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7856,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7854,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7852,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7845,
+ "src": "56748:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7853,
+ "name": "LAMBERT_CONV_RADIUS",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3607,
+ "src": "56753:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56748:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 7855,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "56775:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "56748:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "56736:40:7"
+ },
+ {
+ "assignments": [
+ 7859
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7859,
+ "mutability": "mutable",
+ "name": "i",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7910,
+ "src": "56787:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7858,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "56787:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7863,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7862,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7860,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7851,
+ "src": "56799:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7861,
+ "name": "LAMBERT_POS2_SAMPLE",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3610,
+ "src": "56803:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56799:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "56787:35:7"
+ },
+ {
+ "assignments": [
+ 7865
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7865,
+ "mutability": "mutable",
+ "name": "a",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7910,
+ "src": "56833:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7864,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "56833:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7869,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7868,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7866,
+ "name": "LAMBERT_POS2_SAMPLE",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3610,
+ "src": "56845:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7867,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7859,
+ "src": "56867:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56845:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "56833:35:7"
+ },
+ {
+ "assignments": [
+ 7871
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7871,
+ "mutability": "mutable",
+ "name": "b",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7910,
+ "src": "56879:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7870,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "56879:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7878,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7877,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7872,
+ "name": "LAMBERT_POS2_SAMPLE",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3610,
+ "src": "56891:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7875,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7873,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7859,
+ "src": "56914:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 7874,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "56918:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "56914:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7876,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "56913:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56891:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "56879:41:7"
+ },
+ {
+ "assignments": [
+ 7880
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7880,
+ "mutability": "mutable",
+ "name": "c",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7910,
+ "src": "56931:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7879,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "56931:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7884,
+ "initialValue": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 7881,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "56943:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 7883,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 7882,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7859,
+ "src": "56956:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "56943:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "56931:27:7"
+ },
+ {
+ "assignments": [
+ 7886
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7886,
+ "mutability": "mutable",
+ "name": "d",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7910,
+ "src": "56969:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7885,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "56969:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7892,
+ "initialValue": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 7887,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "56981:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 7891,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7890,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7888,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7859,
+ "src": "56994:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 7889,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "56998:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "56994:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "56981:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "56969:31:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7908,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7905,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7898,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7893,
+ "name": "c",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7880,
+ "src": "57019:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7896,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7894,
+ "name": "b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7871,
+ "src": "57024:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7895,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7851,
+ "src": "57028:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57024:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7897,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "57023:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57019:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7904,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7899,
+ "name": "d",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7886,
+ "src": "57033:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7902,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7900,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7851,
+ "src": "57038:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7901,
+ "name": "a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7865,
+ "src": "57042:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57038:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7903,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "57037:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57033:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57019:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7906,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "57018:27:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7907,
+ "name": "LAMBERT_POS2_SAMPLE",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3610,
+ "src": "57048:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57018:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7849,
+ "id": 7909,
+ "nodeType": "Return",
+ "src": "57011:56:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 7843,
+ "nodeType": "StructuredDocumentation",
+ "src": "56505:149:7",
+ "text": " @dev computes W(x / FIXED_1) / (x / FIXED_1) * FIXED_1\n input range: LAMBERT_CONV_RADIUS + 1 <= x <= LAMBERT_POS2_MAXVAL"
+ },
+ "id": 7911,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "lambertPos2",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 7846,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7845,
+ "mutability": "mutable",
+ "name": "_x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7911,
+ "src": "56681:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7844,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "56681:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "56680:12:7"
+ },
+ "returnParameters": {
+ "id": 7849,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7848,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7911,
+ "src": "56716:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7847,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "56716:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "56715:9:7"
+ },
+ "scope": 8977,
+ "src": "56660:415:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 7960,
+ "nodeType": "Block",
+ "src": "57303:226:7",
+ "statements": [
+ {
+ "assignments": [
+ 7920
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7920,
+ "mutability": "mutable",
+ "name": "l1",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7960,
+ "src": "57314:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7919,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "57314:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7931,
+ "initialValue": {
+ "argumentTypes": null,
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7923,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7921,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7914,
+ "src": "57327:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7922,
+ "name": "OPT_LOG_MAX_VAL",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3601,
+ "src": "57332:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57327:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 7928,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7914,
+ "src": "57378:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 7927,
+ "name": "generalLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5906,
+ "src": "57367:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 7929,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "57367:14:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7930,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "Conditional",
+ "src": "57327:54:7",
+ "trueExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 7925,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7914,
+ "src": "57361:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 7924,
+ "name": "optimalLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6866,
+ "src": "57350:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 7926,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "57350:14:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "57314:67:7"
+ },
+ {
+ "assignments": [
+ 7933
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7933,
+ "mutability": "mutable",
+ "name": "l2",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7960,
+ "src": "57392:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7932,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "57392:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7944,
+ "initialValue": {
+ "argumentTypes": null,
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7936,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7934,
+ "name": "l1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7920,
+ "src": "57405:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7935,
+ "name": "OPT_LOG_MAX_VAL",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3601,
+ "src": "57410:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57405:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 7941,
+ "name": "l1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7920,
+ "src": "57456:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 7940,
+ "name": "generalLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5906,
+ "src": "57445:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 7942,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "57445:14:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7943,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "Conditional",
+ "src": "57405:54:7",
+ "trueExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 7938,
+ "name": "l1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7920,
+ "src": "57439:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 7937,
+ "name": "optimalLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6866,
+ "src": "57428:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 7939,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "57428:14:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "57392:67:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7958,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7956,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7953,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7947,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7945,
+ "name": "l1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7920,
+ "src": "57478:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7946,
+ "name": "l2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7933,
+ "src": "57483:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57478:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7952,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7950,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7948,
+ "name": "l2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7933,
+ "src": "57488:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7949,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "57493:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57488:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7951,
+ "name": "l1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7920,
+ "src": "57503:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57488:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57478:27:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7954,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "57477:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7955,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "57509:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57477:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7957,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7914,
+ "src": "57519:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57477:44:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7918,
+ "id": 7959,
+ "nodeType": "Return",
+ "src": "57470:51:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 7912,
+ "nodeType": "StructuredDocumentation",
+ "src": "57083:149:7",
+ "text": " @dev computes W(x / FIXED_1) / (x / FIXED_1) * FIXED_1\n input range: LAMBERT_POS2_MAXVAL + 1 <= x <= LAMBERT_POS3_MAXVAL"
+ },
+ "id": 7961,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "lambertPos3",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 7915,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7914,
+ "mutability": "mutable",
+ "name": "_x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7961,
+ "src": "57259:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7913,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "57259:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "57258:12:7"
+ },
+ "returnParameters": {
+ "id": 7918,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7917,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7961,
+ "src": "57294:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7916,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "57294:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "57293:9:7"
+ },
+ "scope": 8977,
+ "src": "57238:291:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 8465,
+ "nodeType": "Block",
+ "src": "57791:4551:7",
+ "statements": [
+ {
+ "assignments": [
+ 7970
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7970,
+ "mutability": "mutable",
+ "name": "xi",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8465,
+ "src": "57802:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7969,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "57802:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7972,
+ "initialValue": {
+ "argumentTypes": null,
+ "id": 7971,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "57815:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "57802:15:7"
+ },
+ {
+ "assignments": [
+ 7974
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7974,
+ "mutability": "mutable",
+ "name": "res",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8465,
+ "src": "57828:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7973,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "57828:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7976,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 7975,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "57842:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "57828:15:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7984,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7977,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "57856:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7983,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7980,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7978,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "57862:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7979,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "57867:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57862:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7981,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "57861:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7982,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "57873:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57861:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57856:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7985,
+ "nodeType": "ExpressionStatement",
+ "src": "57856:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7990,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7986,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "57882:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7989,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7987,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "57889:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303030313464323961373361366537623032633336363863376230383830303030303030",
+ "id": 7988,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "57894:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_442849198559406211271427914465280000000_by_1",
+ "typeString": "int_const 4428...(31 digits omitted)...0000"
+ },
+ "value": "0x00000000014d29a73a6e7b02c3668c7b0880000000"
+ },
+ "src": "57889:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57882:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7991,
+ "nodeType": "ExpressionStatement",
+ "src": "57882:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7999,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7992,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "57991:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7998,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7995,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7993,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "57997:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7994,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "58002:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57997:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7996,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "57996:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7997,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "58008:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57996:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57991:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8000,
+ "nodeType": "ExpressionStatement",
+ "src": "57991:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8005,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8001,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "58017:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8004,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8002,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58024:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303030323530346130636439613766373231356236306639626534383030303030303030",
+ "id": 8003,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "58029:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_787287464105611042260316292382720000000_by_1",
+ "typeString": "int_const 7872...(31 digits omitted)...0000"
+ },
+ "value": "0x0000000002504a0cd9a7f7215b60f9be4800000000"
+ },
+ "src": "58024:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58017:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8006,
+ "nodeType": "ExpressionStatement",
+ "src": "58017:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8014,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8007,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58126:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8013,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8010,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8008,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58132:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8009,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "58137:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58132:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8011,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "58131:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8012,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "58143:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58131:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58126:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8015,
+ "nodeType": "ExpressionStatement",
+ "src": "58126:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8020,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8016,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "58152:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8019,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8017,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58159:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303030343834643061313139316330656164323637393637633761346130303030303030",
+ "id": 8018,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "58164:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1537670828331271566914680258560000000000_by_1",
+ "typeString": "int_const 1537...(32 digits omitted)...0000"
+ },
+ "value": "0x000000000484d0a1191c0ead267967c7a4a0000000"
+ },
+ "src": "58159:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58152:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8021,
+ "nodeType": "ExpressionStatement",
+ "src": "58152:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8029,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8022,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58261:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8028,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8025,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8023,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58267:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8024,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "58272:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58267:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8026,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "58266:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8027,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "58278:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58266:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58261:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8030,
+ "nodeType": "ExpressionStatement",
+ "src": "58261:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8035,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8031,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "58287:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8034,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8032,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58294:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303030393565633538306437653834323761346261663236613930613030303030303030",
+ "id": 8033,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "58299:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3188514229627724721154280984150016000000_by_1",
+ "typeString": "int_const 3188...(32 digits omitted)...0000"
+ },
+ "value": "0x00000000095ec580d7e8427a4baf26a90a00000000"
+ },
+ "src": "58294:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58287:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8036,
+ "nodeType": "ExpressionStatement",
+ "src": "58287:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8044,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8037,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58396:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8043,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8040,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8038,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58402:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8039,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "58407:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58402:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8041,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "58401:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8042,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "58413:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58401:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58396:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8045,
+ "nodeType": "ExpressionStatement",
+ "src": "58396:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8050,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8046,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "58422:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8049,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8047,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58429:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303031343430623062653136313561343764626136653562336231663130303030303030",
+ "id": 8048,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "58434:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6891635629803648326702674961498112000000_by_1",
+ "typeString": "int_const 6891...(32 digits omitted)...0000"
+ },
+ "value": "0x000000001440b0be1615a47dba6e5b3b1f10000000"
+ },
+ "src": "58429:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58422:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8051,
+ "nodeType": "ExpressionStatement",
+ "src": "58422:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8059,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8052,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58531:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8058,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8055,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8053,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58537:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8054,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "58542:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58537:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8056,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "58536:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8057,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "58548:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58536:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58531:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8060,
+ "nodeType": "ExpressionStatement",
+ "src": "58531:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8065,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8061,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "58557:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8064,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8062,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58564:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303032643230373630316634366139396234313132343138343030303030303030303030",
+ "id": 8063,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "58569:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_15355854537983727757610740636188672000000_by_1",
+ "typeString": "int_const 1535...(33 digits omitted)...0000"
+ },
+ "value": "0x000000002d207601f46a99b4112418400000000000"
+ },
+ "src": "58564:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58557:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8066,
+ "nodeType": "ExpressionStatement",
+ "src": "58557:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8074,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8067,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58666:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8073,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8070,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8068,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58672:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8069,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "58677:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58672:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8071,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "58671:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8072,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "58683:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58671:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58666:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8075,
+ "nodeType": "ExpressionStatement",
+ "src": "58666:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8080,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8076,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "58692:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8079,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8077,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58699:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303036366562616163346333376336323264643832383861376562316232303030303030",
+ "id": 8078,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "58704:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_35022056686251398262544482483830784000000_by_1",
+ "typeString": "int_const 3502...(33 digits omitted)...0000"
+ },
+ "value": "0x0000000066ebaac4c37c622dd8288a7eb1b2000000"
+ },
+ "src": "58699:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58692:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8081,
+ "nodeType": "ExpressionStatement",
+ "src": "58692:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8089,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8082,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58801:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8088,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8085,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8083,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58807:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8084,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "58812:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58807:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8086,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "58806:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8087,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "58818:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58806:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58801:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8090,
+ "nodeType": "ExpressionStatement",
+ "src": "58801:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8095,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8091,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "58827:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8094,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8092,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58834:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303065663137323430313335663764626434336131626131306366323030303030303030",
+ "id": 8093,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "58839:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_81358244885252463857919590400000000000000_by_1",
+ "typeString": "int_const 8135...(33 digits omitted)...0000"
+ },
+ "value": "0x00000000ef17240135f7dbd43a1ba10cf200000000"
+ },
+ "src": "58834:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58827:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8096,
+ "nodeType": "ExpressionStatement",
+ "src": "58827:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8104,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8097,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58936:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8103,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8100,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8098,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58942:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8099,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "58947:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58942:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8101,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "58941:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8102,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "58953:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58941:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58936:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8105,
+ "nodeType": "ExpressionStatement",
+ "src": "58936:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8110,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8106,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "58962:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8109,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8107,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58969:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303233336333336336373661356562323431363039346138376233363537303030303030",
+ "id": 8108,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "58974:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_191838485670993607105842450247345766400000_by_1",
+ "typeString": "int_const 1918...(34 digits omitted)...0000"
+ },
+ "value": "0x0000000233c33c676a5eb2416094a87b3657000000"
+ },
+ "src": "58969:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58962:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8111,
+ "nodeType": "ExpressionStatement",
+ "src": "58962:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8119,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8112,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59071:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8118,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8115,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8113,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59077:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8114,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "59082:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59077:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8116,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "59076:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8117,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "59088:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59076:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59071:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8120,
+ "nodeType": "ExpressionStatement",
+ "src": "59071:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8125,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8121,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "59097:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8124,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8122,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59104:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303534316364653438626330323534626564343961396638373030303030303030303030",
+ "id": 8123,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "59109:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_457953461925960171898563951427426713600000_by_1",
+ "typeString": "int_const 4579...(34 digits omitted)...0000"
+ },
+ "value": "0x0000000541cde48bc0254bed49a9f8700000000000"
+ },
+ "src": "59104:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59097:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8126,
+ "nodeType": "ExpressionStatement",
+ "src": "59097:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8134,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8127,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59206:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8133,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8130,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8128,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59212:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8129,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "59217:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59212:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8131,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "59211:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8132,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "59223:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59211:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59206:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8135,
+ "nodeType": "ExpressionStatement",
+ "src": "59206:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8140,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8136,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "59232:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8139,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8137,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59239:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030306361653166616432636464346434636238643733616263613064313961343030303030",
+ "id": 8138,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "59244:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1104598668270551480892683896320648806400000_by_1",
+ "typeString": "int_const 1104...(35 digits omitted)...0000"
+ },
+ "value": "0x0000000cae1fad2cdd4d4cb8d73abca0d19a400000"
+ },
+ "src": "59239:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59232:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8141,
+ "nodeType": "ExpressionStatement",
+ "src": "59232:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8149,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8142,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59341:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8148,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8145,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8143,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59347:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8144,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "59352:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59347:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8146,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "59346:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8147,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "59358:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59346:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59341:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8150,
+ "nodeType": "ExpressionStatement",
+ "src": "59341:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8155,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8151,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "59367:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8154,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8152,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59374:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030316564623261613266373630643135633431636565646261393536343030303030303030",
+ "id": 8153,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "59379:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2687947090053832841608264823563773542400000_by_1",
+ "typeString": "int_const 2687...(35 digits omitted)...0000"
+ },
+ "value": "0x0000001edb2aa2f760d15c41ceedba956400000000"
+ },
+ "src": "59374:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59367:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8156,
+ "nodeType": "ExpressionStatement",
+ "src": "59367:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8164,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8157,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59476:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8163,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8160,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8158,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59482:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8159,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "59487:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59482:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8161,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "59481:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8162,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "59493:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59481:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59476:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8165,
+ "nodeType": "ExpressionStatement",
+ "src": "59476:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8170,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8166,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "59502:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8169,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8167,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59509:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030346261386432306432646162643338366339353239363539383431613265323030303030",
+ "id": 8168,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "59514:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6590868088830032065882824000000000000000000_by_1",
+ "typeString": "int_const 6590...(35 digits omitted)...0000"
+ },
+ "value": "0x0000004ba8d20d2dabd386c9529659841a2e200000"
+ },
+ "src": "59509:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59502:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8171,
+ "nodeType": "ExpressionStatement",
+ "src": "59502:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8179,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8172,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59611:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8178,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8175,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8173,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59617:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8174,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "59622:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59617:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8176,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "59616:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8177,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "59628:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59616:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59611:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8180,
+ "nodeType": "ExpressionStatement",
+ "src": "59611:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8185,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8181,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "59637:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8184,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8182,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59644:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030626163303835343662383637636461613230303030303030303030303030303030303030",
+ "id": 8183,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "59649:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_16268396552280633070412438458028041175040000_by_1",
+ "typeString": "int_const 1626...(36 digits omitted)...0000"
+ },
+ "value": "0x000000bac08546b867cdaa20000000000000000000"
+ },
+ "src": "59644:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59637:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8186,
+ "nodeType": "ExpressionStatement",
+ "src": "59637:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8194,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8187,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59746:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8193,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8190,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8188,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59752:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8189,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "59757:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59752:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8191,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "59751:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8192,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "59763:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59751:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59746:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8195,
+ "nodeType": "ExpressionStatement",
+ "src": "59746:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8200,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8196,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "59772:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8199,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8197,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59779:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303031636661386537306330333632356239646237366338656266356262663234383230303030",
+ "id": 8198,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "59784:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_40390462938090940419774080664538139934720000_by_1",
+ "typeString": "int_const 4039...(36 digits omitted)...0000"
+ },
+ "value": "0x000001cfa8e70c03625b9db76c8ebf5bbf24820000"
+ },
+ "src": "59779:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59772:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8201,
+ "nodeType": "ExpressionStatement",
+ "src": "59772:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8209,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8202,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59881:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8208,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8205,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8203,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59887:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8204,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "59892:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59887:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8206,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "59886:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8207,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "59898:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59886:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59881:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8210,
+ "nodeType": "ExpressionStatement",
+ "src": "59881:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8215,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8211,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "59907:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8214,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8212,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59914:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303034383531643939663832303630646632363566333330396232366638323030303030303030",
+ "id": 8213,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "59919:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_100798987671917000666814256179934522245120000_by_1",
+ "typeString": "int_const 1007...(37 digits omitted)...0000"
+ },
+ "value": "0x000004851d99f82060df265f3309b26f8200000000"
+ },
+ "src": "59914:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59907:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8216,
+ "nodeType": "ExpressionStatement",
+ "src": "59907:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8224,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8217,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60016:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8223,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8220,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8218,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60022:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8219,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "60027:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60022:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8221,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "60021:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8222,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "60033:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60021:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60016:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8225,
+ "nodeType": "ExpressionStatement",
+ "src": "60016:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8230,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8226,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "60042:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8229,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8227,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60049:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303062353530643139623132396432373063343466366635356630323737323363626230303030",
+ "id": 8228,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "60054:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_252717199309391137912965664538441463029760000_by_1",
+ "typeString": "int_const 2527...(37 digits omitted)...0000"
+ },
+ "value": "0x00000b550d19b129d270c44f6f55f027723cbb0000"
+ },
+ "src": "60049:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60042:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8231,
+ "nodeType": "ExpressionStatement",
+ "src": "60042:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8239,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8232,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60151:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8238,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8235,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8233,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60157:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8234,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "60162:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60157:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8236,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "60156:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8237,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "60168:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60156:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60151:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8240,
+ "nodeType": "ExpressionStatement",
+ "src": "60151:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8245,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8241,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "60177:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8244,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8242,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60184:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303163383737646164633736316463323732646562363564346230303030303030303030303030",
+ "id": 8243,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "60189:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_636223790447205380259840000000000000000000000_by_1",
+ "typeString": "int_const 6362...(37 digits omitted)...0000"
+ },
+ "value": "0x00001c877dadc761dc272deb65d4b0000000000000"
+ },
+ "src": "60184:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60177:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8246,
+ "nodeType": "ExpressionStatement",
+ "src": "60177:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8254,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8247,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60286:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8253,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8250,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8248,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60292:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8249,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "60297:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60292:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8251,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "60291:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8252,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "60303:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60291:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60286:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8255,
+ "nodeType": "ExpressionStatement",
+ "src": "60286:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8260,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8256,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "60312:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8259,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8257,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60319:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303438313738656365393734373966333361373766326164323261383162363434303663303030",
+ "id": 8258,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "60324:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1607705831573194746802610334450509017233408000_by_1",
+ "typeString": "int_const 1607...(38 digits omitted)...8000"
+ },
+ "value": "0x000048178ece97479f33a77f2ad22a81b64406c000"
+ },
+ "src": "60319:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60312:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8261,
+ "nodeType": "ExpressionStatement",
+ "src": "60312:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8269,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8262,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60421:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8268,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8265,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8263,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60427:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8264,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "60432:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60427:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8266,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "60426:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8267,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "60438:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60426:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60421:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8270,
+ "nodeType": "ExpressionStatement",
+ "src": "60421:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8275,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8271,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "60447:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8274,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8272,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60454:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030306236636138323638623964383130666564663636393565663266386136633030303030303030",
+ "id": 8273,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "60459:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4076376683803157531046819273912505658769408000_by_1",
+ "typeString": "int_const 4076...(38 digits omitted)...8000"
+ },
+ "value": "0x0000b6ca8268b9d810fedf6695ef2f8a6c00000000"
+ },
+ "src": "60454:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60447:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8276,
+ "nodeType": "ExpressionStatement",
+ "src": "60447:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8284,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8277,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60556:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8283,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8280,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8278,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60562:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8279,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "60567:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60562:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8281,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "60561:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8282,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "60573:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60561:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60556:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8285,
+ "nodeType": "ExpressionStatement",
+ "src": "60556:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8290,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8286,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "60582:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8289,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8287,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60589:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030316430653736363331613562303564303037623863623732613763376631316563333665303030",
+ "id": 8288,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "60594:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_10367703484962349537949059901011799777283072000_by_1",
+ "typeString": "int_const 1036...(39 digits omitted)...2000"
+ },
+ "value": "0x0001d0e76631a5b05d007b8cb72a7c7f11ec36e000"
+ },
+ "src": "60589:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60582:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8291,
+ "nodeType": "ExpressionStatement",
+ "src": "60582:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8299,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8292,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60691:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8298,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8295,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8293,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60697:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8294,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "60702:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60697:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8296,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "60696:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8297,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "60708:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60696:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60691:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8300,
+ "nodeType": "ExpressionStatement",
+ "src": "60691:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8305,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8301,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "60717:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8304,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8302,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60724:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030346131633337626439663835666439633663373830303030303030303030303030303030303030",
+ "id": 8303,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "60729:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_26443412100478721735433130630260686447443968000_by_1",
+ "typeString": "int_const 2644...(39 digits omitted)...8000"
+ },
+ "value": "0x0004a1c37bd9f85fd9c6c780000000000000000000"
+ },
+ "src": "60724:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60717:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8306,
+ "nodeType": "ExpressionStatement",
+ "src": "60717:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8314,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8307,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60826:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8313,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8310,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8308,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60832:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8309,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "60837:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60832:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8311,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "60831:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8312,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "60843:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60831:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60826:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8315,
+ "nodeType": "ExpressionStatement",
+ "src": "60826:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8320,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8316,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "60852:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8319,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8317,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60859:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030626438333639663162373032626634393165326562666365653038323530333133623635343030",
+ "id": 8318,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "60864:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_67620617646753089502453804016113281250000000000_by_1",
+ "typeString": "int_const 6762...(39 digits omitted)...0000"
+ },
+ "value": "0x000bd8369f1b702bf491e2ebfcee08250313b65400"
+ },
+ "src": "60859:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60852:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8321,
+ "nodeType": "ExpressionStatement",
+ "src": "60852:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8329,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8322,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60961:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8328,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8325,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8323,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60967:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8324,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "60972:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60967:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8326,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "60966:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8327,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "60978:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60966:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60961:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8330,
+ "nodeType": "ExpressionStatement",
+ "src": "60961:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8335,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8331,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "60987:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8334,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8332,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60994:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303031653563376333326139663663373061623263623539643932323537363464343030303030303030",
+ "id": 8333,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "60999:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_173332210846474760735500226875327576716638945280_by_1",
+ "typeString": "int_const 1733...(40 digits omitted)...5280"
+ },
+ "value": "0x001e5c7c32a9f6c70ab2cb59d9225764d400000000"
+ },
+ "src": "60994:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60987:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8336,
+ "nodeType": "ExpressionStatement",
+ "src": "60987:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8344,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8337,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61096:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8343,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8340,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8338,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61102:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8339,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "61107:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61102:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8341,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "61101:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8342,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "61113:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61101:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61096:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8345,
+ "nodeType": "ExpressionStatement",
+ "src": "61096:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8350,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8346,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "61122:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8349,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8347,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61129:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303034646666353832306531363565393130663935313230613730386537343234393632323165363030",
+ "id": 8348,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "61134:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_445286656448864136819345605176268818347976680960_by_1",
+ "typeString": "int_const 4452...(40 digits omitted)...0960"
+ },
+ "value": "0x004dff5820e165e910f95120a708e742496221e600"
+ },
+ "src": "61129:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61122:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8351,
+ "nodeType": "ExpressionStatement",
+ "src": "61122:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8359,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8352,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61231:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8358,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8355,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8353,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61237:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8354,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "61242:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61237:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8356,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "61236:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8357,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "61248:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61236:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61231:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8360,
+ "nodeType": "ExpressionStatement",
+ "src": "61231:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8365,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8361,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "61257:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8364,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8362,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61264:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303063386338663636646231666365643337386565353065353336303030303030303030303030303030",
+ "id": 8363,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "61269:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1146279770154177862273033179056478989553563074560_by_1",
+ "typeString": "int_const 1146...(41 digits omitted)...4560"
+ },
+ "value": "0x00c8c8f66db1fced378ee50e536000000000000000"
+ },
+ "src": "61264:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61257:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8366,
+ "nodeType": "ExpressionStatement",
+ "src": "61257:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8374,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8367,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61366:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8373,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8370,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8368,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61372:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8369,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "61377:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61372:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8371,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "61371:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8372,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "61383:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61371:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61366:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8375,
+ "nodeType": "ExpressionStatement",
+ "src": "61366:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8380,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8376,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "61392:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8379,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8377,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61399:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303230356462386466666666343562666132393338663132386635393964626631366562313164383830",
+ "id": 8378,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "61404:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2956444461658038477759873400213214992927382689920_by_1",
+ "typeString": "int_const 2956...(41 digits omitted)...9920"
+ },
+ "value": "0x0205db8dffff45bfa2938f128f599dbf16eb11d880"
+ },
+ "src": "61399:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61392:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8381,
+ "nodeType": "ExpressionStatement",
+ "src": "61392:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8389,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8382,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61501:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8388,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8385,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8383,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61507:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8384,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "61512:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61507:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8386,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "61506:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8387,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "61518:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61506:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61501:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8390,
+ "nodeType": "ExpressionStatement",
+ "src": "61501:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8395,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8391,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "61527:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8394,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8392,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61534:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303533613034346562643938343335313439336531373836616633386433396130383030303030303030",
+ "id": 8393,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "61539:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_7638725713617153619200000000000000000000000000000_by_1",
+ "typeString": "int_const 7638...(41 digits omitted)...0000"
+ },
+ "value": "0x053a044ebd984351493e1786af38d39a0800000000"
+ },
+ "src": "61534:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61527:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8396,
+ "nodeType": "ExpressionStatement",
+ "src": "61527:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8404,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8397,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61636:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8403,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8400,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8398,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61642:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8399,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "61647:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61642:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8401,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "61641:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8402,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "61653:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61641:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61636:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8405,
+ "nodeType": "ExpressionStatement",
+ "src": "61636:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8410,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8406,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "61662:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8409,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8407,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61669:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078306438366461653261346363306634373633336135343434373937333538363962343837623539633430",
+ "id": 8408,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "61674:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_19769407354499582705095371848882117322613875645504_by_1",
+ "typeString": "int_const 1976...(42 digits omitted)...5504"
+ },
+ "value": "0x0d86dae2a4cc0f47633a544479735869b487b59c40"
+ },
+ "src": "61669:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61662:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8411,
+ "nodeType": "ExpressionStatement",
+ "src": "61662:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8419,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8412,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61771:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8418,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8415,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8413,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61777:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8414,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "61782:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61777:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8416,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "61776:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8417,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "61788:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61776:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61771:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8420,
+ "nodeType": "ExpressionStatement",
+ "src": "61771:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8425,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8421,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "61797:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8424,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8422,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61804:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078323331303030303030303030303030303030303030303030303030303030303030303030303030303030",
+ "id": 8423,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "61809:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_51243901158914783569516699447114673376686134788096_by_1",
+ "typeString": "int_const 5124...(42 digits omitted)...8096"
+ },
+ "value": "0x231000000000000000000000000000000000000000"
+ },
+ "src": "61804:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61797:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8426,
+ "nodeType": "ExpressionStatement",
+ "src": "61797:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8434,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8427,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61906:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8433,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8430,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8428,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61912:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8429,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "61917:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61912:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8431,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "61911:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8432,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "61923:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61911:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61906:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8435,
+ "nodeType": "ExpressionStatement",
+ "src": "61906:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8440,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8436,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "61932:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8439,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8437,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61939:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078356230343835613736663636343663323033396462313530376364643531623038363439363830383232",
+ "id": 8438,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "61944:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_133022465544965907471119545993290733585983764695074_by_1",
+ "typeString": "int_const 1330...(43 digits omitted)...5074"
+ },
+ "value": "0x5b0485a76f6646c2039db1507cdd51b08649680822"
+ },
+ "src": "61939:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61932:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8441,
+ "nodeType": "ExpressionStatement",
+ "src": "61932:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8449,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8442,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "62041:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8448,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8445,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8443,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "62047:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8444,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "62052:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62047:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8446,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "62046:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8447,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "62058:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62046:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62041:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8450,
+ "nodeType": "ExpressionStatement",
+ "src": "62041:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8455,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8451,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "62067:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8454,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8452,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "62074:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078656339383363343663343935343562633137656661366235623030353565323432323030303030303030",
+ "id": 8453,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "62079:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_345783497216724000335707367685598692782880644399104_by_1",
+ "typeString": "int_const 3457...(43 digits omitted)...9104"
+ },
+ "value": "0xec983c46c49545bc17efa6b5b0055e242200000000"
+ },
+ "src": "62074:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62067:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8456,
+ "nodeType": "ExpressionStatement",
+ "src": "62067:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8463,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8461,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8459,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8457,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "62185:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30786465316263346431396566636163383234343564613735623030303030303030",
+ "id": 8458,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "62191:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_295232799039604140847618609643520000000_by_1",
+ "typeString": "int_const 2952...(31 digits omitted)...0000"
+ },
+ "value": "0xde1bc4d19efcac82445da75b00000000"
+ },
+ "src": "62185:40:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8460,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "62228:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62185:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8462,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "62233:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62185:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7968,
+ "id": 8464,
+ "nodeType": "Return",
+ "src": "62178:62:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 7962,
+ "nodeType": "StructuredDocumentation",
+ "src": "57537:183:7",
+ "text": " @dev computes W(-x / FIXED_1) / (-x / FIXED_1) * FIXED_1\n input range: 1 <= x <= 1 / e * FIXED_1\n auto-generated via 'PrintFunctionLambertNeg1.py'"
+ },
+ "id": 8466,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "lambertNeg1",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 7965,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7964,
+ "mutability": "mutable",
+ "name": "_x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8466,
+ "src": "57747:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7963,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "57747:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "57746:12:7"
+ },
+ "returnParameters": {
+ "id": 7968,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7967,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8466,
+ "src": "57782:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7966,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "57782:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "57781:9:7"
+ },
+ "scope": 8977,
+ "src": "57726:4616:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 8546,
+ "nodeType": "Block",
+ "src": "62643:343:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8491,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 8484,
+ "name": "_tq",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8473,
+ "src": "62655:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8485,
+ "name": "_rp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8475,
+ "src": "62660:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8486,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "62654:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8488,
+ "name": "_tq",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8473,
+ "src": "62679:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8489,
+ "name": "_rp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8475,
+ "src": "62684:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8487,
+ "name": "safeFactors",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8621,
+ "src": "62667:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256,uint256)"
+ }
+ },
+ "id": 8490,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62667:21:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "src": "62654:34:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 8492,
+ "nodeType": "ExpressionStatement",
+ "src": "62654:34:7"
+ },
+ {
+ "assignments": [
+ 8494
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8494,
+ "mutability": "mutable",
+ "name": "f",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8546,
+ "src": "62699:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8493,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "62699:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8501,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8500,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8497,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "62719:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 8495,
+ "name": "_hi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8469,
+ "src": "62711:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8496,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "62711:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8498,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62711:16:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8499,
+ "name": "_lo",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8471,
+ "src": "62730:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62711:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "62699:34:7"
+ },
+ {
+ "assignments": [
+ 8503
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8503,
+ "mutability": "mutable",
+ "name": "g",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8546,
+ "src": "62744:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8502,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "62744:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8514,
+ "initialValue": {
+ "argumentTypes": null,
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8506,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8504,
+ "name": "f",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8494,
+ "src": "62756:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8505,
+ "name": "OPT_LOG_MAX_VAL",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3601,
+ "src": "62760:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62756:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8511,
+ "name": "f",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8494,
+ "src": "62805:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8510,
+ "name": "generalLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5906,
+ "src": "62794:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8512,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62794:13:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8513,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "Conditional",
+ "src": "62756:51:7",
+ "trueExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8508,
+ "name": "f",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8494,
+ "src": "62789:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8507,
+ "name": "optimalLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6866,
+ "src": "62778:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8509,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62778:13:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "62744:63:7"
+ },
+ {
+ "assignments": [
+ 8516
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8516,
+ "mutability": "mutable",
+ "name": "x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8546,
+ "src": "62818:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8515,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "62818:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8523,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8522,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8519,
+ "name": "_tq",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8473,
+ "src": "62836:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 8517,
+ "name": "g",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8503,
+ "src": "62830:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8518,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "62830:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8520,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62830:10:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8521,
+ "name": "_rp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8475,
+ "src": "62843:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62830:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "62818:28:7"
+ },
+ {
+ "assignments": [
+ 8525
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8525,
+ "mutability": "mutable",
+ "name": "y",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8546,
+ "src": "62857:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8524,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "62857:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8534,
+ "initialValue": {
+ "argumentTypes": null,
+ "condition": {
+ "argumentTypes": null,
+ "id": 8526,
+ "name": "_lowerStake",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8477,
+ "src": "62869:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8531,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8516,
+ "src": "62911:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8530,
+ "name": "higherStake",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7336,
+ "src": "62899:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8532,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62899:14:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8533,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "Conditional",
+ "src": "62869:44:7",
+ "trueExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8528,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8516,
+ "src": "62894:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8527,
+ "name": "lowerStake",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7313,
+ "src": "62883:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) view returns (uint256)"
+ }
+ },
+ "id": 8529,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62883:13:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "62857:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8538,
+ "name": "_tq",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8473,
+ "src": "62955:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 8536,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8525,
+ "src": "62949:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8537,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "62949:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8539,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62949:10:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8542,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "62969:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 8540,
+ "name": "_rp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8475,
+ "src": "62961:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8541,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "62961:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8543,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62961:16:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8535,
+ "name": "normalizedWeights",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8656,
+ "src": "62931:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint32_$_t_uint32_$",
+ "typeString": "function (uint256,uint256) pure returns (uint32,uint32)"
+ }
+ },
+ "id": 8544,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62931:47:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint32_$_t_uint32_$",
+ "typeString": "tuple(uint32,uint32)"
+ }
+ },
+ "functionReturnParameters": 8483,
+ "id": 8545,
+ "nodeType": "Return",
+ "src": "62924:54:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8467,
+ "nodeType": "StructuredDocumentation",
+ "src": "62350:146:7",
+ "text": " @dev computes the weights based on \"W(log(hi / lo) * tq / rp) * tq / rp\", where \"W\" is a variation of the Lambert W function."
+ },
+ "id": 8547,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "balancedWeightsByStake",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8478,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8469,
+ "mutability": "mutable",
+ "name": "_hi",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8547,
+ "src": "62534:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8468,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "62534:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8471,
+ "mutability": "mutable",
+ "name": "_lo",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8547,
+ "src": "62547:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8470,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "62547:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8473,
+ "mutability": "mutable",
+ "name": "_tq",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8547,
+ "src": "62560:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8472,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "62560:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8475,
+ "mutability": "mutable",
+ "name": "_rp",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8547,
+ "src": "62573:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8474,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "62573:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8477,
+ "mutability": "mutable",
+ "name": "_lowerStake",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8547,
+ "src": "62586:16:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 8476,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "62586:4:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "62533:70:7"
+ },
+ "returnParameters": {
+ "id": 8483,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8480,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8547,
+ "src": "62627:6:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8479,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "62627:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8482,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8547,
+ "src": "62635:6:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8481,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "62635:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "62626:16:7"
+ },
+ "scope": 8977,
+ "src": "62502:484:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 8620,
+ "nodeType": "Block",
+ "src": "63162:358:7",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 8565,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8561,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8559,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8550,
+ "src": "63177:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8560,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "63183:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63177:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8564,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8562,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8552,
+ "src": "63194:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8563,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "63200:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63194:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "63177:30:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 8570,
+ "nodeType": "IfStatement",
+ "src": "63173:64:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 8566,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8550,
+ "src": "63230:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8567,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8552,
+ "src": "63234:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8568,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "63229:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "functionReturnParameters": 8558,
+ "id": 8569,
+ "nodeType": "Return",
+ "src": "63222:15:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8573,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8571,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8550,
+ "src": "63252:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8572,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "63257:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63252:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 8582,
+ "nodeType": "IfStatement",
+ "src": "63248:66:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8578,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8576,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8574,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8550,
+ "src": "63287:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8575,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "63292:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63287:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8577,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8552,
+ "src": "63302:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63287:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8579,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "63306:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8580,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "63286:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "functionReturnParameters": 8558,
+ "id": 8581,
+ "nodeType": "Return",
+ "src": "63279:35:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8585,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8583,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8552,
+ "src": "63329:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8584,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "63334:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63329:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 8594,
+ "nodeType": "IfStatement",
+ "src": "63325:66:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 8586,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "63364:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8591,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8589,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8587,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8552,
+ "src": "63373:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8588,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "63378:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63373:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8590,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8550,
+ "src": "63388:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63373:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8592,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "63363:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "functionReturnParameters": 8558,
+ "id": 8593,
+ "nodeType": "Return",
+ "src": "63356:35:7"
+ }
+ },
+ {
+ "assignments": [
+ 8596
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8596,
+ "mutability": "mutable",
+ "name": "c",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8620,
+ "src": "63402:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8595,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "63402:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8603,
+ "initialValue": {
+ "argumentTypes": null,
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8599,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8597,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8550,
+ "src": "63414:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8598,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8552,
+ "src": "63419:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63414:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseExpression": {
+ "argumentTypes": null,
+ "id": 8601,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8552,
+ "src": "63429:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8602,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "Conditional",
+ "src": "63414:17:7",
+ "trueExpression": {
+ "argumentTypes": null,
+ "id": 8600,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8550,
+ "src": "63424:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "63402:29:7"
+ },
+ {
+ "assignments": [
+ 8605
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8605,
+ "mutability": "mutable",
+ "name": "n",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8620,
+ "src": "63442:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8604,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "63442:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8611,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8609,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8607,
+ "name": "c",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8596,
+ "src": "63464:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8608,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "63468:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63464:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8606,
+ "name": "floorLog2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5969,
+ "src": "63454:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint8_$",
+ "typeString": "function (uint256) pure returns (uint8)"
+ }
+ },
+ "id": 8610,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "63454:22:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "63442:34:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8614,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8612,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8550,
+ "src": "63495:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8613,
+ "name": "n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8605,
+ "src": "63501:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63495:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8617,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8615,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8552,
+ "src": "63504:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8616,
+ "name": "n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8605,
+ "src": "63510:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63504:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8618,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "63494:18:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "functionReturnParameters": 8558,
+ "id": 8619,
+ "nodeType": "Return",
+ "src": "63487:25:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8548,
+ "nodeType": "StructuredDocumentation",
+ "src": "62994:76:7",
+ "text": " @dev reduces \"a\" and \"b\" while maintaining their ratio."
+ },
+ "id": 8621,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "safeFactors",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8553,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8550,
+ "mutability": "mutable",
+ "name": "_a",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8621,
+ "src": "63097:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8549,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "63097:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8552,
+ "mutability": "mutable",
+ "name": "_b",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8621,
+ "src": "63109:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8551,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "63109:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "63096:24:7"
+ },
+ "returnParameters": {
+ "id": 8558,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8555,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8621,
+ "src": "63144:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8554,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "63144:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8557,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8621,
+ "src": "63153:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8556,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "63153:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "63143:18:7"
+ },
+ "scope": 8977,
+ "src": "63076:444:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 8655,
+ "nodeType": "Block",
+ "src": "63717:157:7",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8635,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8633,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8624,
+ "src": "63732:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8634,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8626,
+ "src": "63738:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63732:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 8641,
+ "nodeType": "IfStatement",
+ "src": "63728:57:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8637,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8624,
+ "src": "63778:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8638,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8626,
+ "src": "63782:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8636,
+ "name": "accurateWeights",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8721,
+ "src": "63762:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint32_$_t_uint32_$",
+ "typeString": "function (uint256,uint256) pure returns (uint32,uint32)"
+ }
+ },
+ "id": 8639,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "63762:23:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint32_$_t_uint32_$",
+ "typeString": "tuple(uint32,uint32)"
+ }
+ },
+ "functionReturnParameters": 8632,
+ "id": 8640,
+ "nodeType": "Return",
+ "src": "63755:30:7"
+ }
+ },
+ {
+ "assignments": [
+ 8643,
+ 8645
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8643,
+ "mutability": "mutable",
+ "name": "y",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8655,
+ "src": "63797:8:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8642,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "63797:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8645,
+ "mutability": "mutable",
+ "name": "x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8655,
+ "src": "63807:8:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8644,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "63807:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8650,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8647,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8626,
+ "src": "63835:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8648,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8624,
+ "src": "63839:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8646,
+ "name": "accurateWeights",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8721,
+ "src": "63819:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint32_$_t_uint32_$",
+ "typeString": "function (uint256,uint256) pure returns (uint32,uint32)"
+ }
+ },
+ "id": 8649,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "63819:23:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint32_$_t_uint32_$",
+ "typeString": "tuple(uint32,uint32)"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "63796:46:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 8651,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8645,
+ "src": "63861:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8652,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8643,
+ "src": "63864:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "id": 8653,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "63860:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint32_$_t_uint32_$",
+ "typeString": "tuple(uint32,uint32)"
+ }
+ },
+ "functionReturnParameters": 8632,
+ "id": 8654,
+ "nodeType": "Return",
+ "src": "63853:13:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8622,
+ "nodeType": "StructuredDocumentation",
+ "src": "63528:93:7",
+ "text": " @dev computes \"MAX_WEIGHT * a / (a + b)\" and \"MAX_WEIGHT * b / (a + b)\"."
+ },
+ "id": 8656,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "normalizedWeights",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8627,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8624,
+ "mutability": "mutable",
+ "name": "_a",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8656,
+ "src": "63654:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8623,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "63654:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8626,
+ "mutability": "mutable",
+ "name": "_b",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8656,
+ "src": "63666:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8625,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "63666:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "63653:24:7"
+ },
+ "returnParameters": {
+ "id": 8632,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8629,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8656,
+ "src": "63701:6:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8628,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "63701:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8631,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8656,
+ "src": "63709:6:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8630,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "63709:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "63700:16:7"
+ },
+ "scope": 8977,
+ "src": "63627:247:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 8720,
+ "nodeType": "Block",
+ "src": "64093:292:7",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8670,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8668,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8659,
+ "src": "64108:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8669,
+ "name": "MAX_UNF_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3619,
+ "src": "64113:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64108:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 8691,
+ "nodeType": "IfStatement",
+ "src": "64104:137:7",
+ "trueBody": {
+ "id": 8690,
+ "nodeType": "Block",
+ "src": "64129:112:7",
+ "statements": [
+ {
+ "assignments": [
+ 8672
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8672,
+ "mutability": "mutable",
+ "name": "c",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8690,
+ "src": "64144:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8671,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64144:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8681,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8680,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8678,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8673,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8659,
+ "src": "64156:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8676,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8674,
+ "name": "MAX_UNF_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3619,
+ "src": "64162:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 8675,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "64179:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "64162:18:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8677,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "64161:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64156:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 8679,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "64184:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "64156:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "64144:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8684,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8682,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8659,
+ "src": "64200:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "/=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 8683,
+ "name": "c",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8672,
+ "src": "64206:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64200:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8685,
+ "nodeType": "ExpressionStatement",
+ "src": "64200:7:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8688,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8686,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8661,
+ "src": "64222:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "/=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 8687,
+ "name": "c",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8672,
+ "src": "64228:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64222:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8689,
+ "nodeType": "ExpressionStatement",
+ "src": "64222:7:7"
+ }
+ ]
+ }
+ },
+ {
+ "assignments": [
+ 8693
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8693,
+ "mutability": "mutable",
+ "name": "x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8720,
+ "src": "64251:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8692,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64251:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8703,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8697,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8695,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8659,
+ "src": "64272:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8696,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "64277:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "64272:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8700,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8661,
+ "src": "64296:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 8698,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8659,
+ "src": "64289:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8699,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "add",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22271,
+ "src": "64289:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8701,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "64289:10:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8694,
+ "name": "roundDiv",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8747,
+ "src": "64263:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8702,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "64263:37:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "64251:49:7"
+ },
+ {
+ "assignments": [
+ 8705
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8705,
+ "mutability": "mutable",
+ "name": "y",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8720,
+ "src": "64311:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8704,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64311:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8709,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8708,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8706,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "64323:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8707,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8693,
+ "src": "64336:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64323:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "64311:26:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8712,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8693,
+ "src": "64363:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8711,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "64356:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_uint32_$",
+ "typeString": "type(uint32)"
+ },
+ "typeName": {
+ "id": 8710,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "64356:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 8713,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "64356:9:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8716,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8705,
+ "src": "64374:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8715,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "64367:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_uint32_$",
+ "typeString": "type(uint32)"
+ },
+ "typeName": {
+ "id": 8714,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "64367:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 8717,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "64367:9:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "id": 8718,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "64355:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint32_$_t_uint32_$",
+ "typeString": "tuple(uint32,uint32)"
+ }
+ },
+ "functionReturnParameters": 8667,
+ "id": 8719,
+ "nodeType": "Return",
+ "src": "64348:29:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8657,
+ "nodeType": "StructuredDocumentation",
+ "src": "63882:117:7",
+ "text": " @dev computes \"MAX_WEIGHT * a / (a + b)\" and \"MAX_WEIGHT * b / (a + b)\", assuming that \"a <= b\"."
+ },
+ "id": 8721,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "accurateWeights",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8662,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8659,
+ "mutability": "mutable",
+ "name": "_a",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8721,
+ "src": "64030:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8658,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64030:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8661,
+ "mutability": "mutable",
+ "name": "_b",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8721,
+ "src": "64042:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8660,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64042:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "64029:24:7"
+ },
+ "returnParameters": {
+ "id": 8667,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8664,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8721,
+ "src": "64077:6:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8663,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "64077:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8666,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8721,
+ "src": "64085:6:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8665,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "64085:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "64076:16:7"
+ },
+ "scope": 8977,
+ "src": "64005:380:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 8746,
+ "nodeType": "Block",
+ "src": "64584:59:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8744,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8733,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8731,
+ "name": "_n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8724,
+ "src": "64602:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8732,
+ "name": "_d",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8726,
+ "src": "64607:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64602:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8743,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8736,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8734,
+ "name": "_n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8724,
+ "src": "64612:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "%",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8735,
+ "name": "_d",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8726,
+ "src": "64617:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64612:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8741,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8737,
+ "name": "_d",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8726,
+ "src": "64623:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8740,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8738,
+ "name": "_d",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8726,
+ "src": "64628:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 8739,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "64633:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "64628:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64623:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8742,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "64622:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64612:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64602:33:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8730,
+ "id": 8745,
+ "nodeType": "Return",
+ "src": "64595:40:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8722,
+ "nodeType": "StructuredDocumentation",
+ "src": "64393:111:7",
+ "text": " @dev computes the nearest integer to a given quotient without overflowing or underflowing."
+ },
+ "id": 8747,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "roundDiv",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8727,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8724,
+ "mutability": "mutable",
+ "name": "_n",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8747,
+ "src": "64528:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8723,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64528:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8726,
+ "mutability": "mutable",
+ "name": "_d",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8747,
+ "src": "64540:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8725,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64540:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "64527:24:7"
+ },
+ "returnParameters": {
+ "id": 8730,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8729,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8747,
+ "src": "64575:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8728,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64575:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "64574:9:7"
+ },
+ "scope": 8977,
+ "src": "64510:133:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 8768,
+ "nodeType": "Block",
+ "src": "65019:97:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8762,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8750,
+ "src": "65058:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8763,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8752,
+ "src": "65067:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8764,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8754,
+ "src": "65084:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8765,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8756,
+ "src": "65100:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8761,
+ "name": "purchaseTargetAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5085,
+ "src": "65037:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8766,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "65037:71:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8760,
+ "id": 8767,
+ "nodeType": "Return",
+ "src": "65030:78:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8748,
+ "nodeType": "StructuredDocumentation",
+ "src": "64651:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "29a00e7c",
+ "id": 8769,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "calculatePurchaseReturn",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8757,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8750,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8769,
+ "src": "64750:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8749,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64750:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8752,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8769,
+ "src": "64805:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8751,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64805:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8754,
+ "mutability": "mutable",
+ "name": "_reserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8769,
+ "src": "64868:21:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8753,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "64868:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8756,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8769,
+ "src": "64929:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8755,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64929:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "64749:196:7"
+ },
+ "returnParameters": {
+ "id": 8760,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8759,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8769,
+ "src": "65005:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8758,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "65005:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "65004:9:7"
+ },
+ "scope": 8977,
+ "src": "64717:399:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8790,
+ "nodeType": "Block",
+ "src": "65472:93:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8784,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8772,
+ "src": "65507:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8785,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8774,
+ "src": "65516:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8786,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8776,
+ "src": "65533:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8787,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8778,
+ "src": "65549:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8783,
+ "name": "saleTargetAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5199,
+ "src": "65490:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8788,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "65490:67:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8782,
+ "id": 8789,
+ "nodeType": "Return",
+ "src": "65483:74:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8770,
+ "nodeType": "StructuredDocumentation",
+ "src": "65124:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "49f9b0f7",
+ "id": 8791,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "calculateSaleReturn",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8779,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8772,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8791,
+ "src": "65219:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8771,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "65219:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8774,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8791,
+ "src": "65270:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8773,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "65270:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8776,
+ "mutability": "mutable",
+ "name": "_reserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8791,
+ "src": "65329:21:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8775,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "65329:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8778,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8791,
+ "src": "65386:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8777,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "65386:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "65218:184:7"
+ },
+ "returnParameters": {
+ "id": 8782,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8781,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8791,
+ "src": "65458:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8780,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "65458:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "65457:9:7"
+ },
+ "scope": 8977,
+ "src": "65190:375:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8815,
+ "nodeType": "Block",
+ "src": "66058:149:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8808,
+ "name": "_sourceReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8794,
+ "src": "66101:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8809,
+ "name": "_sourceReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8796,
+ "src": "66124:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8810,
+ "name": "_targetReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8798,
+ "src": "66146:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8811,
+ "name": "_targetReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8800,
+ "src": "66169:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8812,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8802,
+ "src": "66191:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8807,
+ "name": "crossReserveTargetAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5305,
+ "src": "66076:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint32_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint32,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8813,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "66076:123:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8806,
+ "id": 8814,
+ "nodeType": "Return",
+ "src": "66069:130:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8792,
+ "nodeType": "StructuredDocumentation",
+ "src": "65573:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "79c1b450",
+ "id": 8816,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "calculateCrossReserveReturn",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8803,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8794,
+ "mutability": "mutable",
+ "name": "_sourceReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8816,
+ "src": "65676:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8793,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "65676:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8796,
+ "mutability": "mutable",
+ "name": "_sourceReserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8816,
+ "src": "65749:27:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8795,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "65749:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8798,
+ "mutability": "mutable",
+ "name": "_targetReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8816,
+ "src": "65820:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8797,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "65820:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8800,
+ "mutability": "mutable",
+ "name": "_targetReserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8816,
+ "src": "65893:27:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8799,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "65893:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8802,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8816,
+ "src": "65964:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8801,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "65964:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "65675:305:7"
+ },
+ "returnParameters": {
+ "id": 8806,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8805,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8816,
+ "src": "66044:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8804,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "66044:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "66043:9:7"
+ },
+ "scope": 8977,
+ "src": "65639:568:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8840,
+ "nodeType": "Block",
+ "src": "66712:149:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8833,
+ "name": "_sourceReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8819,
+ "src": "66755:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8834,
+ "name": "_sourceReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8821,
+ "src": "66778:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8835,
+ "name": "_targetReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8823,
+ "src": "66800:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8836,
+ "name": "_targetReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8825,
+ "src": "66823:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8837,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8827,
+ "src": "66845:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8832,
+ "name": "crossReserveTargetAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5305,
+ "src": "66730:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint32_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint32,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8838,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "66730:123:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8831,
+ "id": 8839,
+ "nodeType": "Return",
+ "src": "66723:130:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8817,
+ "nodeType": "StructuredDocumentation",
+ "src": "66215:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "65098bb3",
+ "id": 8841,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "calculateCrossConnectorReturn",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8828,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8819,
+ "mutability": "mutable",
+ "name": "_sourceReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8841,
+ "src": "66320:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8818,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "66320:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8821,
+ "mutability": "mutable",
+ "name": "_sourceReserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8841,
+ "src": "66395:27:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8820,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "66395:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8823,
+ "mutability": "mutable",
+ "name": "_targetReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8841,
+ "src": "66468:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8822,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "66468:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8825,
+ "mutability": "mutable",
+ "name": "_targetReserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8841,
+ "src": "66543:27:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8824,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "66543:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8827,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8841,
+ "src": "66616:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8826,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "66616:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "66319:313:7"
+ },
+ "returnParameters": {
+ "id": 8831,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8830,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8841,
+ "src": "66698:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8829,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "66698:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "66697:9:7"
+ },
+ "scope": 8977,
+ "src": "66281:580:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8862,
+ "nodeType": "Block",
+ "src": "67206:84:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8856,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8844,
+ "src": "67233:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8857,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8846,
+ "src": "67242:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8858,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8848,
+ "src": "67259:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8859,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8850,
+ "src": "67274:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8855,
+ "name": "fundCost",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5413,
+ "src": "67224:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8860,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "67224:58:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8854,
+ "id": 8861,
+ "nodeType": "Return",
+ "src": "67217:65:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8842,
+ "nodeType": "StructuredDocumentation",
+ "src": "66869:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "1da6bbfb",
+ "id": 8863,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "calculateFundCost",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8851,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8844,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8863,
+ "src": "66962:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8843,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "66962:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8846,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8863,
+ "src": "67011:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8845,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67011:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8848,
+ "mutability": "mutable",
+ "name": "_reserveRatio",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8863,
+ "src": "67068:20:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8847,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "67068:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8850,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8863,
+ "src": "67122:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8849,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67122:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "66961:177:7"
+ },
+ "returnParameters": {
+ "id": 8854,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8853,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8863,
+ "src": "67192:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8852,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67192:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "67191:9:7"
+ },
+ "scope": 8977,
+ "src": "66935:355:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8884,
+ "nodeType": "Block",
+ "src": "67670:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8878,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8866,
+ "src": "67711:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8879,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8868,
+ "src": "67720:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8880,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8870,
+ "src": "67737:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8881,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8872,
+ "src": "67752:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8877,
+ "name": "liquidateReserveAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5626,
+ "src": "67688:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8882,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "67688:72:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8876,
+ "id": 8883,
+ "nodeType": "Return",
+ "src": "67681:79:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8864,
+ "nodeType": "StructuredDocumentation",
+ "src": "67298:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "abfd231d",
+ "id": 8885,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "calculateLiquidateReturn",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8873,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8866,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8885,
+ "src": "67398:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8865,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67398:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8868,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8885,
+ "src": "67454:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8867,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67454:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8870,
+ "mutability": "mutable",
+ "name": "_reserveRatio",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8885,
+ "src": "67518:20:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8869,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "67518:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8872,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8885,
+ "src": "67579:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8871,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67579:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "67397:198:7"
+ },
+ "returnParameters": {
+ "id": 8876,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8875,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8885,
+ "src": "67656:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8874,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67656:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "67655:9:7"
+ },
+ "scope": 8977,
+ "src": "67364:404:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8906,
+ "nodeType": "Block",
+ "src": "68089:97:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8900,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8888,
+ "src": "68128:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8901,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8890,
+ "src": "68137:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8902,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8892,
+ "src": "68154:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8903,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8894,
+ "src": "68170:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8899,
+ "name": "purchaseTargetAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5085,
+ "src": "68107:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8904,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "68107:71:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8898,
+ "id": 8905,
+ "nodeType": "Return",
+ "src": "68100:78:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8886,
+ "nodeType": "StructuredDocumentation",
+ "src": "67776:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "48d73fed",
+ "id": 8907,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "purchaseRate",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8895,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8888,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8907,
+ "src": "67864:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8887,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67864:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8890,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8907,
+ "src": "67908:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8889,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67908:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8892,
+ "mutability": "mutable",
+ "name": "_reserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8907,
+ "src": "67960:21:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8891,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "67960:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8894,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8907,
+ "src": "68010:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8893,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68010:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "67863:163:7"
+ },
+ "returnParameters": {
+ "id": 8898,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8897,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8907,
+ "src": "68075:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8896,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68075:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "68074:9:7"
+ },
+ "scope": 8977,
+ "src": "67842:344:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8928,
+ "nodeType": "Block",
+ "src": "68487:93:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8922,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8910,
+ "src": "68522:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8923,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8912,
+ "src": "68531:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8924,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8914,
+ "src": "68548:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8925,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8916,
+ "src": "68564:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8921,
+ "name": "saleTargetAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5199,
+ "src": "68505:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8926,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "68505:67:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8920,
+ "id": 8927,
+ "nodeType": "Return",
+ "src": "68498:74:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8908,
+ "nodeType": "StructuredDocumentation",
+ "src": "68194:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "f732f1c9",
+ "id": 8929,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "saleRate",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8917,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8910,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8929,
+ "src": "68278:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8909,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68278:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8912,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8929,
+ "src": "68318:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8911,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68318:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8914,
+ "mutability": "mutable",
+ "name": "_reserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8929,
+ "src": "68366:21:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8913,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "68366:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8916,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8929,
+ "src": "68412:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8915,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68412:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "68277:151:7"
+ },
+ "returnParameters": {
+ "id": 8920,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8919,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8929,
+ "src": "68473:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8918,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68473:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "68472:9:7"
+ },
+ "scope": 8977,
+ "src": "68260:320:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8953,
+ "nodeType": "Block",
+ "src": "69007:149:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8946,
+ "name": "_sourceReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8932,
+ "src": "69050:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8947,
+ "name": "_sourceReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8934,
+ "src": "69073:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8948,
+ "name": "_targetReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8936,
+ "src": "69095:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8949,
+ "name": "_targetReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8938,
+ "src": "69118:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8950,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8940,
+ "src": "69140:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8945,
+ "name": "crossReserveTargetAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5305,
+ "src": "69025:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint32_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint32,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8951,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "69025:123:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8944,
+ "id": 8952,
+ "nodeType": "Return",
+ "src": "69018:130:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8930,
+ "nodeType": "StructuredDocumentation",
+ "src": "68588:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "9d114108",
+ "id": 8954,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "crossReserveRate",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8941,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8932,
+ "mutability": "mutable",
+ "name": "_sourceReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8954,
+ "src": "68680:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8931,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68680:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8934,
+ "mutability": "mutable",
+ "name": "_sourceReserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8954,
+ "src": "68742:27:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8933,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "68742:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8936,
+ "mutability": "mutable",
+ "name": "_targetReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8954,
+ "src": "68802:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8935,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68802:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8938,
+ "mutability": "mutable",
+ "name": "_targetReserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8954,
+ "src": "68864:27:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8937,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "68864:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8940,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8954,
+ "src": "68924:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8939,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68924:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "68679:261:7"
+ },
+ "returnParameters": {
+ "id": 8944,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8943,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8954,
+ "src": "68993:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8942,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68993:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "68992:9:7"
+ },
+ "scope": 8977,
+ "src": "68654:502:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8975,
+ "nodeType": "Block",
+ "src": "69481:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8969,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8957,
+ "src": "69522:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8970,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8959,
+ "src": "69531:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8971,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8961,
+ "src": "69548:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8972,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8963,
+ "src": "69563:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8968,
+ "name": "liquidateReserveAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5626,
+ "src": "69499:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8973,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "69499:72:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8967,
+ "id": 8974,
+ "nodeType": "Return",
+ "src": "69492:79:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8955,
+ "nodeType": "StructuredDocumentation",
+ "src": "69164:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "35b49af4",
+ "id": 8976,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "liquidateRate",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8964,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8957,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8976,
+ "src": "69253:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8956,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "69253:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8959,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8976,
+ "src": "69298:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8958,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "69298:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8961,
+ "mutability": "mutable",
+ "name": "_reserveRatio",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8976,
+ "src": "69351:20:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8960,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "69351:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8963,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8976,
+ "src": "69401:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8962,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "69401:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "69252:165:7"
+ },
+ "returnParameters": {
+ "id": 8967,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8966,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8976,
+ "src": "69467:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8965,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "69467:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "69466:9:7"
+ },
+ "scope": 8977,
+ "src": "69230:349:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ }
+ ],
+ "scope": 8978,
+ "src": "157:69425:7"
+ }
+ ],
+ "src": "52:69532:7"
+ },
+ "legacyAST": {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/BancorFormula.sol",
+ "exportedSymbols": {
+ "BancorFormula": [
+ 8977
+ ]
+ },
+ "id": 8978,
+ "license": "SEE LICENSE IN LICENSE",
+ "nodeType": "SourceUnit",
+ "nodes": [
+ {
+ "id": 3564,
+ "literals": [
+ "solidity",
+ "0.6",
+ ".12"
+ ],
+ "nodeType": "PragmaDirective",
+ "src": "52:23:7"
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IBancorFormula.sol",
+ "file": "./interfaces/IBancorFormula.sol",
+ "id": 3565,
+ "nodeType": "ImportDirective",
+ "scope": 8978,
+ "sourceUnit": 13178,
+ "src": "77:41:7",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/SafeMath.sol",
+ "file": "../utility/SafeMath.sol",
+ "id": 3566,
+ "nodeType": "ImportDirective",
+ "scope": 8978,
+ "sourceUnit": 22355,
+ "src": "120:33:7",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "abstract": false,
+ "baseContracts": [
+ {
+ "arguments": null,
+ "baseName": {
+ "contractScope": null,
+ "id": 3567,
+ "name": "IBancorFormula",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13177,
+ "src": "183:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorFormula_$13177",
+ "typeString": "contract IBancorFormula"
+ }
+ },
+ "id": 3568,
+ "nodeType": "InheritanceSpecifier",
+ "src": "183:14:7"
+ }
+ ],
+ "contractDependencies": [
+ 13177
+ ],
+ "contractKind": "contract",
+ "documentation": null,
+ "fullyImplemented": true,
+ "id": 8977,
+ "linearizedBaseContracts": [
+ 8977,
+ 13177
+ ],
+ "name": "BancorFormula",
+ "nodeType": "ContractDefinition",
+ "nodes": [
+ {
+ "id": 3571,
+ "libraryName": {
+ "contractScope": null,
+ "id": 3569,
+ "name": "SafeMath",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 22354,
+ "src": "211:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_SafeMath_$22354",
+ "typeString": "library SafeMath"
+ }
+ },
+ "nodeType": "UsingForDirective",
+ "src": "205:27:7",
+ "typeName": {
+ "id": 3570,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "224:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ },
+ {
+ "constant": true,
+ "id": 3574,
+ "mutability": "constant",
+ "name": "ONE",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "240:32:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3572,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "240:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 3573,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "271:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3577,
+ "mutability": "constant",
+ "name": "MAX_WEIGHT",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "279:44:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 3575,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "279:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "31303030303030",
+ "id": 3576,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "316:7:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1000000_by_1",
+ "typeString": "int_const 1000000"
+ },
+ "value": "1000000"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3580,
+ "mutability": "constant",
+ "name": "MIN_PRECISION",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "330:41:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 3578,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "330:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "3332",
+ "id": 3579,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "369:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_32_by_1",
+ "typeString": "int_const 32"
+ },
+ "value": "32"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3583,
+ "mutability": "constant",
+ "name": "MAX_PRECISION",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "378:42:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 3581,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "378:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "313237",
+ "id": 3582,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "417:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_127_by_1",
+ "typeString": "int_const 127"
+ },
+ "value": "127"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3586,
+ "mutability": "constant",
+ "name": "FIXED_1",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "484:70:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3584,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "484:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "3078303830303030303030303030303030303030303030303030303030303030303030",
+ "id": 3585,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "519:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_170141183460469231731687303715884105728_by_1",
+ "typeString": "int_const 1701...(31 digits omitted)...5728"
+ },
+ "value": "0x080000000000000000000000000000000"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3589,
+ "mutability": "constant",
+ "name": "FIXED_2",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "561:70:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3587,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "561:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "3078313030303030303030303030303030303030303030303030303030303030303030",
+ "id": 3588,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "596:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_340282366920938463463374607431768211456_by_1",
+ "typeString": "int_const 3402...(31 digits omitted)...1456"
+ },
+ "value": "0x100000000000000000000000000000000"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3592,
+ "mutability": "constant",
+ "name": "MAX_NUM",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "638:70:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3590,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "638:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "3078323030303030303030303030303030303030303030303030303030303030303030",
+ "id": 3591,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "673:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_680564733841876926926749214863536422912_by_1",
+ "typeString": "int_const 6805...(31 digits omitted)...2912"
+ },
+ "value": "0x200000000000000000000000000000000"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3595,
+ "mutability": "constant",
+ "name": "LN2_NUMERATOR",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "772:76:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3593,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "772:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "307833663830666530336638306665303366383066653033663830666530336638",
+ "id": 3594,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "815:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_5275695611177340518812009417546793976_by_1",
+ "typeString": "int_const 5275...(29 digits omitted)...3976"
+ },
+ "value": "0x3f80fe03f80fe03f80fe03f80fe03f8"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3598,
+ "mutability": "constant",
+ "name": "LN2_DENOMINATOR",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "855:76:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3596,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "855:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "307835623964653164313062663431303364363437623039353538393762613830",
+ "id": 3597,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "898:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_7611219895485218073587121647846406784_by_1",
+ "typeString": "int_const 7611...(29 digits omitted)...6784"
+ },
+ "value": "0x5b9de1d10bf4103d647b0955897ba80"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3601,
+ "mutability": "constant",
+ "name": "OPT_LOG_MAX_VAL",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "1029:78:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3599,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1029:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "3078313562663061386231343537363935333535666238616334303465376137396533",
+ "id": 3600,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "1072:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_462491687273110168575455517921668397539_by_1",
+ "typeString": "int_const 4624...(31 digits omitted)...7539"
+ },
+ "value": "0x15bf0a8b1457695355fb8ac404e7a79e3"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3604,
+ "mutability": "constant",
+ "name": "OPT_EXP_MAX_VAL",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "1114:78:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3602,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1114:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "3078383030303030303030303030303030303030303030303030303030303030303030",
+ "id": 3603,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "1157:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2722258935367507707706996859454145691648_by_1",
+ "typeString": "int_const 2722...(32 digits omitted)...1648"
+ },
+ "value": "0x800000000000000000000000000000000"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3607,
+ "mutability": "constant",
+ "name": "LAMBERT_CONV_RADIUS",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "1253:83:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3605,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1253:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "307830303266313661633663353964653666386435643666363363313438326137633836",
+ "id": 3606,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "1300:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_62591443491685266058625363149075414150_by_1",
+ "typeString": "int_const 6259...(30 digits omitted)...4150"
+ },
+ "value": "0x002f16ac6c59de6f8d5d6f63c1482a7c86"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3610,
+ "mutability": "constant",
+ "name": "LAMBERT_POS2_SAMPLE",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "1343:83:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3608,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1343:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "307830303033303630633138333036306331383330363063313833303630633138333036",
+ "id": 3609,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "1390:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4019083073869351930669778827934270214_by_1",
+ "typeString": "int_const 4019...(29 digits omitted)...0214"
+ },
+ "value": "0x0003060c183060c183060c183060c18306"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3613,
+ "mutability": "constant",
+ "name": "LAMBERT_POS2_MAXVAL",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "1433:83:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3611,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1433:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "307830316166313661633663353964653666386435643666363363313438326137633830",
+ "id": 3612,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "1480:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_573014993873092961253687274296727731328_by_1",
+ "typeString": "int_const 5730...(31 digits omitted)...1328"
+ },
+ "value": "0x01af16ac6c59de6f8d5d6f63c1482a7c80"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3616,
+ "mutability": "constant",
+ "name": "LAMBERT_POS3_MAXVAL",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "1523:83:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3614,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1523:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "307836623232643433653732633332363533396363656565663862623438663235356666",
+ "id": 3615,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "1570:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_36456509045932913977692090597752865707519_by_1",
+ "typeString": "int_const 3645...(33 digits omitted)...7519"
+ },
+ "value": "0x6b22d43e72c326539cceeef8bb48f255ff"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 3619,
+ "mutability": "constant",
+ "name": "MAX_UNF_WEIGHT",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "1666:104:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 3617,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1666:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "3078313063366637613062356564386433366234633766333439333835383336323166616663386230303739613238333464323666613366636339656139",
+ "id": 3618,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "1708:62:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_115792089237316195423570985008687907853269984665640564039457584007913129_by_1",
+ "typeString": "int_const 1157...(64 digits omitted)...3129"
+ },
+ "value": "0x10c6f7a0b5ed8d36b4c7f34938583621fafc8b0079a2834d26fa3fcc9ea9"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": false,
+ "id": 3623,
+ "mutability": "mutable",
+ "name": "maxExpArray",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "1828:32:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 3620,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1828:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3622,
+ "length": {
+ "argumentTypes": null,
+ "hexValue": "313238",
+ "id": 3621,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "1836:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_128_by_1",
+ "typeString": "int_const 128"
+ },
+ "value": "128"
+ },
+ "nodeType": "ArrayTypeName",
+ "src": "1828:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage_ptr",
+ "typeString": "uint256[128]"
+ }
+ },
+ "value": null,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 4202,
+ "nodeType": "Block",
+ "src": "1902:8456:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3630,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3626,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4025:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3628,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3332",
+ "id": 3627,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4038:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_32_by_1",
+ "typeString": "int_const 32"
+ },
+ "value": "32"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4025:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831633335666564643134666666666666666666666666666666666666666666666666",
+ "id": 3629,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4044:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_9599678685041259184274752310158947254271_by_1",
+ "typeString": "int_const 9599...(32 digits omitted)...4271"
+ },
+ "value": "0x1c35fedd14ffffffffffffffffffffffff"
+ },
+ "src": "4025:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3631,
+ "nodeType": "ExpressionStatement",
+ "src": "4025:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3636,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3632,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4091:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3634,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3333",
+ "id": 3633,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4104:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_33_by_1",
+ "typeString": "int_const 33"
+ },
+ "value": "33"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4091:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831623063653433623332336666666666666666666666666666666666666666666666",
+ "id": 3635,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4110:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_9204759687141885226475603015507577405439_by_1",
+ "typeString": "int_const 9204...(32 digits omitted)...5439"
+ },
+ "value": "0x1b0ce43b323fffffffffffffffffffffff"
+ },
+ "src": "4091:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3637,
+ "nodeType": "ExpressionStatement",
+ "src": "4091:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3642,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3638,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4157:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3640,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3334",
+ "id": 3639,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4170:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_34_by_1",
+ "typeString": "int_const 34"
+ },
+ "value": "34"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4157:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831396630303238656331666666666666666666666666666666666666666666666666",
+ "id": 3641,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4176:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_8826087172077985712041017634911355404287_by_1",
+ "typeString": "int_const 8826...(32 digits omitted)...4287"
+ },
+ "value": "0x19f0028ec1ffffffffffffffffffffffff"
+ },
+ "src": "4157:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3643,
+ "nodeType": "ExpressionStatement",
+ "src": "4157:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3648,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3644,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4223:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3646,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3335",
+ "id": 3645,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4236:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_35_by_1",
+ "typeString": "int_const 35"
+ },
+ "value": "35"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4223:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831386465643931663065376666666666666666666666666666666666666666666666",
+ "id": 3647,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4242:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_8462992779488582574159642900919291478015_by_1",
+ "typeString": "int_const 8462...(32 digits omitted)...8015"
+ },
+ "value": "0x18ded91f0e7fffffffffffffffffffffff"
+ },
+ "src": "4223:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3649,
+ "nodeType": "ExpressionStatement",
+ "src": "4223:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3654,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3650,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4289:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3652,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3336",
+ "id": 3651,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4302:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_36_by_1",
+ "typeString": "int_const 36"
+ },
+ "value": "36"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4289:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831376438656337663034313766666666666666666666666666666666666666666666",
+ "id": 3653,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4308:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_8114835644520100661580084966409403105279_by_1",
+ "typeString": "int_const 8114...(32 digits omitted)...5279"
+ },
+ "value": "0x17d8ec7f0417ffffffffffffffffffffff"
+ },
+ "src": "4289:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3655,
+ "nodeType": "ExpressionStatement",
+ "src": "4289:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3660,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3656,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4355:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3658,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3337",
+ "id": 3657,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4368:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_37_by_1",
+ "typeString": "int_const 37"
+ },
+ "value": "37"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4355:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831366464633635353663646266666666666666666666666666666666666666666666",
+ "id": 3659,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4374:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_7781001266736647064069662172832600162303_by_1",
+ "typeString": "int_const 7781...(32 digits omitted)...2303"
+ },
+ "value": "0x16ddc6556cdbffffffffffffffffffffff"
+ },
+ "src": "4355:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3661,
+ "nodeType": "ExpressionStatement",
+ "src": "4355:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3666,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3662,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4421:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3664,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3338",
+ "id": 3663,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4434:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_38_by_1",
+ "typeString": "int_const 38"
+ },
+ "value": "38"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4421:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831356563663532373736613166666666666666666666666666666666666666666666",
+ "id": 3665,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4440:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_7460900425488323202194551465008353509375_by_1",
+ "typeString": "int_const 7460...(32 digits omitted)...9375"
+ },
+ "value": "0x15ecf52776a1ffffffffffffffffffffff"
+ },
+ "src": "4421:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3667,
+ "nodeType": "ExpressionStatement",
+ "src": "4421:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3672,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3668,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4487:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3670,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3339",
+ "id": 3669,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4500:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_39_by_1",
+ "typeString": "int_const 39"
+ },
+ "value": "39"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4487:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831353036306332353663623266666666666666666666666666666666666666666666",
+ "id": 3671,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4506:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_7153968139937914349310206877837545177087_by_1",
+ "typeString": "int_const 7153...(32 digits omitted)...7087"
+ },
+ "value": "0x15060c256cb2ffffffffffffffffffffff"
+ },
+ "src": "4487:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3673,
+ "nodeType": "ExpressionStatement",
+ "src": "4487:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3678,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3674,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4553:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3676,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3430",
+ "id": 3675,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4566:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_40_by_1",
+ "typeString": "int_const 40"
+ },
+ "value": "40"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4553:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831343238613266393864373266666666666666666666666666666666666666666666",
+ "id": 3677,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4572:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6859662671868001546166128217910528704511_by_1",
+ "typeString": "int_const 6859...(32 digits omitted)...4511"
+ },
+ "value": "0x1428a2f98d72ffffffffffffffffffffff"
+ },
+ "src": "4553:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3679,
+ "nodeType": "ExpressionStatement",
+ "src": "4553:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3684,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3680,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4619:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3682,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3431",
+ "id": 3681,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4632:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_41_by_1",
+ "typeString": "int_const 41"
+ },
+ "value": "41"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4619:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831333534353539386535633233666666666666666666666666666666666666666666",
+ "id": 3683,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4638:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6577464569506365633454696454958677491711_by_1",
+ "typeString": "int_const 6577...(32 digits omitted)...1711"
+ },
+ "value": "0x13545598e5c23fffffffffffffffffffff"
+ },
+ "src": "4619:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3685,
+ "nodeType": "ExpressionStatement",
+ "src": "4619:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3690,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3686,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4685:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3688,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3432",
+ "id": 3687,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4698:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_42_by_1",
+ "typeString": "int_const 42"
+ },
+ "value": "42"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4685:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831323838633431363163653164666666666666666666666666666666666666666666",
+ "id": 3689,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4704:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6306875750689218484600399768107450630143_by_1",
+ "typeString": "int_const 6306...(32 digits omitted)...0143"
+ },
+ "value": "0x1288c4161ce1dfffffffffffffffffffff"
+ },
+ "src": "4685:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3691,
+ "nodeType": "ExpressionStatement",
+ "src": "4685:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3696,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3692,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4751:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3694,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3433",
+ "id": 3693,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4764:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_43_by_1",
+ "typeString": "int_const 43"
+ },
+ "value": "43"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4751:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831316335393237363163363636666666666666666666666666666666666666666666",
+ "id": 3695,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4770:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6047418623741353042663269283551730728959_by_1",
+ "typeString": "int_const 6047...(32 digits omitted)...8959"
+ },
+ "value": "0x11c592761c666fffffffffffffffffffff"
+ },
+ "src": "4751:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3697,
+ "nodeType": "ExpressionStatement",
+ "src": "4751:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3702,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3698,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4817:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3700,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3434",
+ "id": 3699,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4830:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_44_by_1",
+ "typeString": "int_const 44"
+ },
+ "value": "44"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4817:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831313061363838363830613735376666666666666666666666666666666666666666",
+ "id": 3701,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4836:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_5798635244522972732941736303310812479487_by_1",
+ "typeString": "int_const 5798...(32 digits omitted)...9487"
+ },
+ "value": "0x110a688680a757ffffffffffffffffffff"
+ },
+ "src": "4817:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3703,
+ "nodeType": "ExpressionStatement",
+ "src": "4817:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3708,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3704,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4883:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3706,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3435",
+ "id": 3705,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4896:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_45_by_1",
+ "typeString": "int_const 45"
+ },
+ "value": "45"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4883:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307831303536663162356265646637376666666666666666666666666666666666666666",
+ "id": 3707,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4902:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_5560086508154074440893281558760167309311_by_1",
+ "typeString": "int_const 5560...(32 digits omitted)...9311"
+ },
+ "value": "0x1056f1b5bedf77ffffffffffffffffffff"
+ },
+ "src": "4883:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3709,
+ "nodeType": "ExpressionStatement",
+ "src": "4883:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3714,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3710,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "4949:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3712,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3436",
+ "id": 3711,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4962:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_46_by_1",
+ "typeString": "int_const 46"
+ },
+ "value": "46"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4949:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830666161646365636565666638626666666666666666666666666666666666666666",
+ "id": 3713,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "4968:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_5331351373990447379730864460340651884543_by_1",
+ "typeString": "int_const 5331...(32 digits omitted)...4543"
+ },
+ "value": "0x0faadceceeff8bffffffffffffffffffff"
+ },
+ "src": "4949:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3715,
+ "nodeType": "ExpressionStatement",
+ "src": "4949:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3720,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3716,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5015:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3718,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3437",
+ "id": 3717,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5028:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_47_by_1",
+ "typeString": "int_const 47"
+ },
+ "value": "47"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5015:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830663035646336623237656461646666666666666666666666666666666666666666",
+ "id": 3719,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5034:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_5112026122483163422598731111238626967551_by_1",
+ "typeString": "int_const 5112...(32 digits omitted)...7551"
+ },
+ "value": "0x0f05dc6b27edadffffffffffffffffffff"
+ },
+ "src": "5015:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3721,
+ "nodeType": "ExpressionStatement",
+ "src": "5015:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3726,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3722,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5081:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3724,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3438",
+ "id": 3723,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5094:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_48_by_1",
+ "typeString": "int_const 48"
+ },
+ "value": "48"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5081:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830653637613561323564613431303766666666666666666666666666666666666666",
+ "id": 3725,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5100:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4901723642609993464238960471454494228479_by_1",
+ "typeString": "int_const 4901...(32 digits omitted)...8479"
+ },
+ "value": "0x0e67a5a25da4107fffffffffffffffffff"
+ },
+ "src": "5081:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3727,
+ "nodeType": "ExpressionStatement",
+ "src": "5081:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3732,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3728,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5147:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3730,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3439",
+ "id": 3729,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5160:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_49_by_1",
+ "typeString": "int_const 49"
+ },
+ "value": "49"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5147:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830646366663131356231346565646666666666666666666666666666666666666666",
+ "id": 3731,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5166:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4700072748620998500994433661760029327359_by_1",
+ "typeString": "int_const 4700...(32 digits omitted)...7359"
+ },
+ "value": "0x0dcff115b14eedffffffffffffffffffff"
+ },
+ "src": "5147:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3733,
+ "nodeType": "ExpressionStatement",
+ "src": "5147:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3738,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3734,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5213:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3736,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3530",
+ "id": 3735,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5226:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_50_by_1",
+ "typeString": "int_const 50"
+ },
+ "value": "50"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5213:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830643365376133393234333132333966666666666666666666666666666666666666",
+ "id": 3737,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5232:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4506717524892375150236886652795301658623_by_1",
+ "typeString": "int_const 4506...(32 digits omitted)...8623"
+ },
+ "value": "0x0d3e7a392431239fffffffffffffffffff"
+ },
+ "src": "5213:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3739,
+ "nodeType": "ExpressionStatement",
+ "src": "5213:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3744,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3740,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5279:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3742,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3531",
+ "id": 3741,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5292:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_51_by_1",
+ "typeString": "int_const 51"
+ },
+ "value": "51"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5279:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830636232666635323965623731653466666666666666666666666666666666666666",
+ "id": 3743,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5298:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4321316697732212547034601541953113817087_by_1",
+ "typeString": "int_const 4321...(32 digits omitted)...7087"
+ },
+ "value": "0x0cb2ff529eb71e4fffffffffffffffffff"
+ },
+ "src": "5279:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3745,
+ "nodeType": "ExpressionStatement",
+ "src": "5279:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3750,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3746,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5345:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3748,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3532",
+ "id": 3747,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5358:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_52_by_1",
+ "typeString": "int_const 52"
+ },
+ "value": "52"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5345:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830633264343135633364623937346166666666666666666666666666666666666666",
+ "id": 3749,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5364:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4143543033029384782309349805264440655871_by_1",
+ "typeString": "int_const 4143...(32 digits omitted)...5871"
+ },
+ "value": "0x0c2d415c3db974afffffffffffffffffff"
+ },
+ "src": "5345:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3751,
+ "nodeType": "ExpressionStatement",
+ "src": "5345:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3756,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3752,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5411:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3754,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3533",
+ "id": 3753,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5424:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_53_by_1",
+ "typeString": "int_const 53"
+ },
+ "value": "53"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5411:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830626164303365376438383366363962666666666666666666666666666666666666",
+ "id": 3755,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5430:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3973082758682431363936722477132055314431_by_1",
+ "typeString": "int_const 3973...(32 digits omitted)...4431"
+ },
+ "value": "0x0bad03e7d883f69bffffffffffffffffff"
+ },
+ "src": "5411:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3757,
+ "nodeType": "ExpressionStatement",
+ "src": "5411:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3762,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3758,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5477:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3760,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3534",
+ "id": 3759,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5490:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_54_by_1",
+ "typeString": "int_const 54"
+ },
+ "value": "54"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5477:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830623332306430336232633334336435666666666666666666666666666666666666",
+ "id": 3761,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5496:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3809635010789003168527049097368437784575_by_1",
+ "typeString": "int_const 3809...(32 digits omitted)...4575"
+ },
+ "value": "0x0b320d03b2c343d5ffffffffffffffffff"
+ },
+ "src": "5477:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3763,
+ "nodeType": "ExpressionStatement",
+ "src": "5477:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3768,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3764,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5543:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3766,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3535",
+ "id": 3765,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5556:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_55_by_1",
+ "typeString": "int_const 55"
+ },
+ "value": "55"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5543:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830616263323532303465303238323864666666666666666666666666666666666666",
+ "id": 3767,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5562:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3652911302618395401280222488042819026943_by_1",
+ "typeString": "int_const 3652...(32 digits omitted)...6943"
+ },
+ "value": "0x0abc25204e02828dffffffffffffffffff"
+ },
+ "src": "5543:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3769,
+ "nodeType": "ExpressionStatement",
+ "src": "5543:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3774,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3770,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5609:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3772,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3536",
+ "id": 3771,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5622:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_56_by_1",
+ "typeString": "int_const 56"
+ },
+ "value": "56"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5609:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830613462313666373465653462623230376666666666666666666666666666666666",
+ "id": 3773,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5628:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3502635015429898674229017626613836152831_by_1",
+ "typeString": "int_const 3502...(32 digits omitted)...2831"
+ },
+ "value": "0x0a4b16f74ee4bb207fffffffffffffffff"
+ },
+ "src": "5609:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3775,
+ "nodeType": "ExpressionStatement",
+ "src": "5609:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3780,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3776,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5675:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3778,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3537",
+ "id": 3777,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5688:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_57_by_1",
+ "typeString": "int_const 57"
+ },
+ "value": "57"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5675:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830396465616637333661633166353639666666666666666666666666666666666666",
+ "id": 3779,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5694:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3358540910238258030536300376569398951935_by_1",
+ "typeString": "int_const 3358...(32 digits omitted)...1935"
+ },
+ "value": "0x09deaf736ac1f569ffffffffffffffffff"
+ },
+ "src": "5675:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3781,
+ "nodeType": "ExpressionStatement",
+ "src": "5675:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3786,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3782,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5741:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3784,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3538",
+ "id": 3783,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5754:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_58_by_1",
+ "typeString": "int_const 58"
+ },
+ "value": "58"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5741:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830393736626439393532633761613935376666666666666666666666666666666666",
+ "id": 3785,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5760:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3220374659664501751807634855053158776831_by_1",
+ "typeString": "int_const 3220...(32 digits omitted)...6831"
+ },
+ "value": "0x0976bd9952c7aa957fffffffffffffffff"
+ },
+ "src": "5741:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3787,
+ "nodeType": "ExpressionStatement",
+ "src": "5741:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3792,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3788,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5807:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3790,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3539",
+ "id": 3789,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5820:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_59_by_1",
+ "typeString": "int_const 59"
+ },
+ "value": "59"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5807:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830393133313237313932326561613630366666666666666666666666666666666666",
+ "id": 3791,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5826:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3087892399045852422628542596524428754943_by_1",
+ "typeString": "int_const 3087...(32 digits omitted)...4943"
+ },
+ "value": "0x09131271922eaa606fffffffffffffffff"
+ },
+ "src": "5807:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3793,
+ "nodeType": "ExpressionStatement",
+ "src": "5807:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3798,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3794,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5873:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3796,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3630",
+ "id": 3795,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5886:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_60_by_1",
+ "typeString": "int_const 60"
+ },
+ "value": "60"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5873:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830386233383066333535383636386334366666666666666666666666666666666666",
+ "id": 3797,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5892:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2960860296012425255212778080756987592703_by_1",
+ "typeString": "int_const 2960...(32 digits omitted)...2703"
+ },
+ "value": "0x08b380f3558668c46fffffffffffffffff"
+ },
+ "src": "5873:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3799,
+ "nodeType": "ExpressionStatement",
+ "src": "5873:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3804,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3800,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "5939:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3802,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3631",
+ "id": 3801,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5952:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_61_by_1",
+ "typeString": "int_const 61"
+ },
+ "value": "61"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "5939:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830383537646466303131376566613231356266666666666666666666666666666666",
+ "id": 3803,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "5958:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2839054137771012724926516325250418868223_by_1",
+ "typeString": "int_const 2839...(32 digits omitted)...8223"
+ },
+ "value": "0x0857ddf0117efa215bffffffffffffffff"
+ },
+ "src": "5939:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3805,
+ "nodeType": "ExpressionStatement",
+ "src": "5939:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3810,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3806,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6005:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3808,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3632",
+ "id": 3807,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6018:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_62_by_1",
+ "typeString": "int_const 62"
+ },
+ "value": "62"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6005:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830376666666666666666666666666666666666666666666666666666666666666666",
+ "id": 3809,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6024:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2722258935367507707706996859454145691647_by_1",
+ "typeString": "int_const 2722...(32 digits omitted)...1647"
+ },
+ "value": "0x07ffffffffffffffffffffffffffffffff"
+ },
+ "src": "6005:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3811,
+ "nodeType": "ExpressionStatement",
+ "src": "6005:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3816,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3812,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6071:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3814,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3633",
+ "id": 3813,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6084:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_63_by_1",
+ "typeString": "int_const 63"
+ },
+ "value": "63"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6071:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830376162626636663661626239643038376666666666666666666666666666666666",
+ "id": 3815,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6090:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2610268544229484780765045556213696167935_by_1",
+ "typeString": "int_const 2610...(32 digits omitted)...7935"
+ },
+ "value": "0x07abbf6f6abb9d087fffffffffffffffff"
+ },
+ "src": "6071:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3817,
+ "nodeType": "ExpressionStatement",
+ "src": "6071:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3822,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3818,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6137:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3820,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3634",
+ "id": 3819,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6150:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_64_by_1",
+ "typeString": "int_const 64"
+ },
+ "value": "64"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6137:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830373561663632636261633935663764666137666666666666666666666666666666",
+ "id": 3821,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6156:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2502885300319193958571922333378000453631_by_1",
+ "typeString": "int_const 2502...(32 digits omitted)...3631"
+ },
+ "value": "0x075af62cbac95f7dfa7fffffffffffffff"
+ },
+ "src": "6137:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3823,
+ "nodeType": "ExpressionStatement",
+ "src": "6137:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3828,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3824,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6203:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3826,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3635",
+ "id": 3825,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6216:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_65_by_1",
+ "typeString": "int_const 65"
+ },
+ "value": "65"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6203:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830373064376662373435326531383761633133666666666666666666666666666666",
+ "id": 3827,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6222:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2399919671254773659805118819743970623487_by_1",
+ "typeString": "int_const 2399...(32 digits omitted)...3487"
+ },
+ "value": "0x070d7fb7452e187ac13fffffffffffffff"
+ },
+ "src": "6203:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3829,
+ "nodeType": "ExpressionStatement",
+ "src": "6203:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3834,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3830,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6269:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3832,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3636",
+ "id": 3831,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6282:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_66_by_1",
+ "typeString": "int_const 66"
+ },
+ "value": "66"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6269:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830366333333930656363386166333739323935666666666666666666666666666666",
+ "id": 3833,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6288:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2301189921783908737703717501630802821119_by_1",
+ "typeString": "int_const 2301...(32 digits omitted)...1119"
+ },
+ "value": "0x06c3390ecc8af379295fffffffffffffff"
+ },
+ "src": "6269:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3835,
+ "nodeType": "ExpressionStatement",
+ "src": "6269:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3840,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3836,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6335:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3838,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3637",
+ "id": 3837,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6348:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_67_by_1",
+ "typeString": "int_const 67"
+ },
+ "value": "67"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6335:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830363763303061336230376666633031666436666666666666666666666666666666",
+ "id": 3839,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6354:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2206521793019491601704439134261549727743_by_1",
+ "typeString": "int_const 2206...(32 digits omitted)...7743"
+ },
+ "value": "0x067c00a3b07ffc01fd6fffffffffffffff"
+ },
+ "src": "6335:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3841,
+ "nodeType": "ExpressionStatement",
+ "src": "6335:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3846,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3842,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6401:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3844,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3638",
+ "id": 3843,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6414:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_68_by_1",
+ "typeString": "int_const 68"
+ },
+ "value": "68"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6401:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830363337623634376333396362623964336432376666666666666666666666666666",
+ "id": 3845,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6420:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2115748194871134515168564783402692116479_by_1",
+ "typeString": "int_const 2115...(32 digits omitted)...6479"
+ },
+ "value": "0x0637b647c39cbb9d3d27ffffffffffffff"
+ },
+ "src": "6401:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3847,
+ "nodeType": "ExpressionStatement",
+ "src": "6401:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3852,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3848,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6467:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3850,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3639",
+ "id": 3849,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6480:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_69_by_1",
+ "typeString": "int_const 69"
+ },
+ "value": "69"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6467:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830356636336231666331303464626433393538376666666666666666666666666666",
+ "id": 3851,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6486:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2028708911129671949307566740521183346687_by_1",
+ "typeString": "int_const 2028...(32 digits omitted)...6687"
+ },
+ "value": "0x05f63b1fc104dbd39587ffffffffffffff"
+ },
+ "src": "6467:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3853,
+ "nodeType": "ExpressionStatement",
+ "src": "6467:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3858,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3854,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6533:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3856,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3730",
+ "id": 3855,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6546:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_70_by_1",
+ "typeString": "int_const 70"
+ },
+ "value": "70"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6533:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830356237373139353562333665313266373233356666666666666666666666666666",
+ "id": 3857,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6552:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1945250316684124513375052119057996185599_by_1",
+ "typeString": "int_const 1945...(32 digits omitted)...5599"
+ },
+ "value": "0x05b771955b36e12f7235ffffffffffffff"
+ },
+ "src": "6533:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3859,
+ "nodeType": "ExpressionStatement",
+ "src": "6533:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3864,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3860,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6599:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3862,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3731",
+ "id": 3861,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6612:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_71_by_1",
+ "typeString": "int_const 71"
+ },
+ "value": "71"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6599:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830353762336434396464613834353536643666366666666666666666666666666666",
+ "id": 3863,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6618:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1865225106372009884014199587421481336831_by_1",
+ "typeString": "int_const 1865...(32 digits omitted)...6831"
+ },
+ "value": "0x057b3d49dda84556d6f6ffffffffffffff"
+ },
+ "src": "6599:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3865,
+ "nodeType": "ExpressionStatement",
+ "src": "6599:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3870,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3866,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6665:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3868,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3732",
+ "id": 3867,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6678:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_72_by_1",
+ "typeString": "int_const 72"
+ },
+ "value": "72"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6665:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830353431383330393562326338656365636633306666666666666666666666666666",
+ "id": 3869,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6684:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1788492034984419117666073304513300660223_by_1",
+ "typeString": "int_const 1788...(32 digits omitted)...0223"
+ },
+ "value": "0x054183095b2c8ececf30ffffffffffffff"
+ },
+ "src": "6665:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3871,
+ "nodeType": "ExpressionStatement",
+ "src": "6665:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3876,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3872,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6731:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3874,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3733",
+ "id": 3873,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6744:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_73_by_1",
+ "typeString": "int_const 73"
+ },
+ "value": "73"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6731:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830353061323862653633356361326238383866373766666666666666666666666666",
+ "id": 3875,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6750:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1714915667966964990208967912165996494847_by_1",
+ "typeString": "int_const 1714...(32 digits omitted)...4847"
+ },
+ "value": "0x050a28be635ca2b888f77fffffffffffff"
+ },
+ "src": "6731:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3877,
+ "nodeType": "ExpressionStatement",
+ "src": "6731:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3882,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3878,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6797:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3880,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3734",
+ "id": 3879,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6810:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_74_by_1",
+ "typeString": "int_const 74"
+ },
+ "value": "74"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6797:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830346435313536363339373038633964623333633366666666666666666666666666",
+ "id": 3881,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6816:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1644366142376587317378242124992063995903_by_1",
+ "typeString": "int_const 1644...(32 digits omitted)...5903"
+ },
+ "value": "0x04d5156639708c9db33c3fffffffffffff"
+ },
+ "src": "6797:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3883,
+ "nodeType": "ExpressionStatement",
+ "src": "6797:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3888,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3884,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6863:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3886,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3735",
+ "id": 3885,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6876:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_75_by_1",
+ "typeString": "int_const 75"
+ },
+ "value": "75"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6863:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830346132333130353837333837356264353264666466666666666666666666666666",
+ "id": 3887,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6882:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1576718937672301888428671268411708276735_by_1",
+ "typeString": "int_const 1576...(32 digits omitted)...6735"
+ },
+ "value": "0x04a23105873875bd52dfdfffffffffffff"
+ },
+ "src": "6863:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3889,
+ "nodeType": "ExpressionStatement",
+ "src": "6863:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3894,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3890,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6929:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3892,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3736",
+ "id": 3891,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6942:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_76_by_1",
+ "typeString": "int_const 76"
+ },
+ "value": "76"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6929:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830343731363439643837313939616139393037353666666666666666666666666666",
+ "id": 3893,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6948:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1511854655935336643558907106913628979199_by_1",
+ "typeString": "int_const 1511...(32 digits omitted)...9199"
+ },
+ "value": "0x0471649d87199aa990756fffffffffffff"
+ },
+ "src": "6929:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3895,
+ "nodeType": "ExpressionStatement",
+ "src": "6929:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3900,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3896,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "6995:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3898,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3737",
+ "id": 3897,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7008:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_77_by_1",
+ "typeString": "int_const 77"
+ },
+ "value": "77"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "6995:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830343432396132316130323964346331343537636662666666666666666666666666",
+ "id": 3899,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7014:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1449658811130741678082357454851673161727_by_1",
+ "typeString": "int_const 1449...(32 digits omitted)...1727"
+ },
+ "value": "0x04429a21a029d4c1457cfbffffffffffff"
+ },
+ "src": "6995:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3901,
+ "nodeType": "ExpressionStatement",
+ "src": "6995:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3906,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3902,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7061:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3904,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3738",
+ "id": 3903,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7074:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_78_by_1",
+ "typeString": "int_const 78"
+ },
+ "value": "78"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7061:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830343135626336643666623764643731616632636233666666666666666666666666",
+ "id": 3905,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7080:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1390021627038517938156314751863424548863_by_1",
+ "typeString": "int_const 1390...(32 digits omitted)...8863"
+ },
+ "value": "0x0415bc6d6fb7dd71af2cb3ffffffffffff"
+ },
+ "src": "7061:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3907,
+ "nodeType": "ExpressionStatement",
+ "src": "7061:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3912,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3908,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7127:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3910,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3739",
+ "id": 3909,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7140:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_79_by_1",
+ "typeString": "int_const 79"
+ },
+ "value": "79"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7127:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830336561623733623362626665323832323433636531666666666666666666666666",
+ "id": 3911,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7146:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1332837843497611250583009129150422188031_by_1",
+ "typeString": "int_const 1332...(32 digits omitted)...8031"
+ },
+ "value": "0x03eab73b3bbfe282243ce1ffffffffffff"
+ },
+ "src": "7127:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3913,
+ "nodeType": "ExpressionStatement",
+ "src": "7127:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3918,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3914,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7193:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3916,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3830",
+ "id": 3915,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7206:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_80_by_1",
+ "typeString": "int_const 80"
+ },
+ "value": "80"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7193:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830336331373731616339666236623463313865323239666666666666666666666666",
+ "id": 3917,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7212:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1278006530620790610545644364558728429567_by_1",
+ "typeString": "int_const 1278...(32 digits omitted)...9567"
+ },
+ "value": "0x03c1771ac9fb6b4c18e229ffffffffffff"
+ },
+ "src": "7193:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3919,
+ "nodeType": "ExpressionStatement",
+ "src": "7193:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3924,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3920,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7259:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3922,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3831",
+ "id": 3921,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7272:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_81_by_1",
+ "typeString": "int_const 81"
+ },
+ "value": "81"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7259:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830333939653936383937363930343138663738353235376666666666666666666666",
+ "id": 3923,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7278:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1225430910652498332846748256431392161791_by_1",
+ "typeString": "int_const 1225...(32 digits omitted)...1791"
+ },
+ "value": "0x0399e96897690418f785257fffffffffff"
+ },
+ "src": "7259:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3925,
+ "nodeType": "ExpressionStatement",
+ "src": "7259:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3930,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3926,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7325:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3928,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3832",
+ "id": 3927,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7338:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_82_by_1",
+ "typeString": "int_const 82"
+ },
+ "value": "82"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7325:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830333733666334353663353362623737396266306561396666666666666666666666",
+ "id": 3929,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7344:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1175018187155249585623915264673694351359_by_1",
+ "typeString": "int_const 1175...(32 digits omitted)...1359"
+ },
+ "value": "0x0373fc456c53bb779bf0ea9fffffffffff"
+ },
+ "src": "7325:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3931,
+ "nodeType": "ExpressionStatement",
+ "src": "7325:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3936,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3932,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7391:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3934,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3833",
+ "id": 3933,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7404:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_83_by_1",
+ "typeString": "int_const 83"
+ },
+ "value": "83"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7391:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830333466396538653439306334386536376536616238626666666666666666666666",
+ "id": 3935,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7410:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1126679381223093780446468558216906145791_by_1",
+ "typeString": "int_const 1126...(32 digits omitted)...5791"
+ },
+ "value": "0x034f9e8e490c48e67e6ab8bfffffffffff"
+ },
+ "src": "7391:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3937,
+ "nodeType": "ExpressionStatement",
+ "src": "7391:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3942,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3938,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7457:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3940,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3834",
+ "id": 3939,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7470:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_84_by_1",
+ "typeString": "int_const 84"
+ },
+ "value": "84"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7457:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830333263626664346137616463373930353630623333333766666666666666666666",
+ "id": 3941,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7476:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1080329174433053119456411494679599644671_by_1",
+ "typeString": "int_const 1080...(32 digits omitted)...4671"
+ },
+ "value": "0x032cbfd4a7adc790560b3337ffffffffff"
+ },
+ "src": "7457:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3943,
+ "nodeType": "ExpressionStatement",
+ "src": "7457:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3948,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3944,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7523:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3946,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3835",
+ "id": 3945,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7536:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_85_by_1",
+ "typeString": "int_const 85"
+ },
+ "value": "85"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7523:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830333062353035373066366535643261636361393436313366666666666666666666",
+ "id": 3947,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7542:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1035885758257346189907937735244580388863_by_1",
+ "typeString": "int_const 1035...(32 digits omitted)...8863"
+ },
+ "value": "0x030b50570f6e5d2acca94613ffffffffff"
+ },
+ "src": "7523:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3949,
+ "nodeType": "ExpressionStatement",
+ "src": "7523:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3954,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3950,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7589:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3952,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3836",
+ "id": 3951,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7602:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_86_by_1",
+ "typeString": "int_const 86"
+ },
+ "value": "86"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7589:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830326562343066396636323066646136623536633238363166666666666666666666",
+ "id": 3953,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7608:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_993270689670607839608468400662101622783_by_1",
+ "typeString": "int_const 9932...(31 digits omitted)...2783"
+ },
+ "value": "0x02eb40f9f620fda6b56c2861ffffffffff"
+ },
+ "src": "7589:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3955,
+ "nodeType": "ExpressionStatement",
+ "src": "7589:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3960,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3956,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7655:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3958,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3837",
+ "id": 3957,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7668:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_87_by_1",
+ "typeString": "int_const 87"
+ },
+ "value": "87"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7655:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830326363383334306563623064306635323061366166353866666666666666666666",
+ "id": 3959,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7674:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_952408752697250790372885759853747765247_by_1",
+ "typeString": "int_const 9524...(31 digits omitted)...5247"
+ },
+ "value": "0x02cc8340ecb0d0f520a6af58ffffffffff"
+ },
+ "src": "7655:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3961,
+ "nodeType": "ExpressionStatement",
+ "src": "7655:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3966,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3962,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7721:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3964,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3838",
+ "id": 3963,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7734:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_88_by_1",
+ "typeString": "int_const 88"
+ },
+ "value": "88"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7721:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830326166303934383133383061306133356366316261303266666666666666666666",
+ "id": 3965,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7740:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_913227825654598849673391073164504596479_by_1",
+ "typeString": "int_const 9132...(31 digits omitted)...6479"
+ },
+ "value": "0x02af09481380a0a35cf1ba02ffffffffff"
+ },
+ "src": "7721:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3967,
+ "nodeType": "ExpressionStatement",
+ "src": "7721:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3972,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3968,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7787:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3970,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3839",
+ "id": 3969,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7800:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_89_by_1",
+ "typeString": "int_const 89"
+ },
+ "value": "89"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7787:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830323932633562646433623932656338313032383762316233666666666666666666",
+ "id": 3971,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7806:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_875658753857474668265023456619450597375_by_1",
+ "typeString": "int_const 8756...(31 digits omitted)...7375"
+ },
+ "value": "0x0292c5bdd3b92ec810287b1b3fffffffff"
+ },
+ "src": "7787:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3973,
+ "nodeType": "ExpressionStatement",
+ "src": "7787:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3978,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3974,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7853:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3976,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3930",
+ "id": 3975,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7866:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_90_by_1",
+ "typeString": "int_const 90"
+ },
+ "value": "90"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7853:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830323737616264636461623037643561373761633664366239666666666666666666",
+ "id": 3977,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7872:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_839635227559564507480479102760887779327_by_1",
+ "typeString": "int_const 8396...(31 digits omitted)...9327"
+ },
+ "value": "0x0277abdcdab07d5a77ac6d6b9fffffffff"
+ },
+ "src": "7853:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3979,
+ "nodeType": "ExpressionStatement",
+ "src": "7853:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3984,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3980,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7919:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3982,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3931",
+ "id": 3981,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7932:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_91_by_1",
+ "typeString": "int_const 91"
+ },
+ "value": "91"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7919:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830323564616636363534623165616135356664363464663565666666666666666666",
+ "id": 3983,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7938:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_805093664916125437948904238798044397567_by_1",
+ "typeString": "int_const 8050...(31 digits omitted)...7567"
+ },
+ "value": "0x025daf6654b1eaa55fd64df5efffffffff"
+ },
+ "src": "7919:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3985,
+ "nodeType": "ExpressionStatement",
+ "src": "7919:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3990,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3986,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "7985:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3988,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3932",
+ "id": 3987,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7998:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_92_by_1",
+ "typeString": "int_const 92"
+ },
+ "value": "92"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "7985:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830323434633439633634386261613938313932646365383862376666666666666666",
+ "id": 3989,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8004:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_771973099761463105605096142810743046143_by_1",
+ "typeString": "int_const 7719...(31 digits omitted)...6143"
+ },
+ "value": "0x0244c49c648baa98192dce88b7ffffffff"
+ },
+ "src": "7985:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3991,
+ "nodeType": "ExpressionStatement",
+ "src": "7985:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 3996,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3992,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8051:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 3994,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3933",
+ "id": 3993,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8064:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_93_by_1",
+ "typeString": "int_const 93"
+ },
+ "value": "93"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8051:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830323263653033636435363139613331316232343731323638626666666666666666",
+ "id": 3995,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8070:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_740215074003106313787373698556008333311_by_1",
+ "typeString": "int_const 7402...(31 digits omitted)...3311"
+ },
+ "value": "0x022ce03cd5619a311b2471268bffffffff"
+ },
+ "src": "8051:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 3997,
+ "nodeType": "ExpressionStatement",
+ "src": "8051:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4002,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 3998,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8117:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4000,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3934",
+ "id": 3999,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8130:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_94_by_1",
+ "typeString": "int_const 94"
+ },
+ "value": "94"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8117:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830323135663737633034356662653838353635346134346130666666666666666666",
+ "id": 4001,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8136:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_709763534442753181219281418466841591807_by_1",
+ "typeString": "int_const 7097...(31 digits omitted)...1807"
+ },
+ "value": "0x0215f77c045fbe885654a44a0fffffffff"
+ },
+ "src": "8117:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4003,
+ "nodeType": "ExpressionStatement",
+ "src": "8117:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4008,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4004,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8183:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4006,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3935",
+ "id": 4005,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8196:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_95_by_1",
+ "typeString": "int_const 95"
+ },
+ "value": "95"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8183:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830316666666666666666666666666666666666666666666666666666666666666666",
+ "id": 4007,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8202:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_680564733841876926926749214863536422911_by_1",
+ "typeString": "int_const 6805...(31 digits omitted)...2911"
+ },
+ "value": "0x01ffffffffffffffffffffffffffffffff"
+ },
+ "src": "8183:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4009,
+ "nodeType": "ExpressionStatement",
+ "src": "8183:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4014,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4010,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8249:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4012,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3936",
+ "id": 4011,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8262:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_96_by_1",
+ "typeString": "int_const 96"
+ },
+ "value": "96"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8249:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830316561656664626461616565373432316663346433656465356666666666666666",
+ "id": 4013,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8268:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_652567136057371195186997586203332575231_by_1",
+ "typeString": "int_const 6525...(31 digits omitted)...5231"
+ },
+ "value": "0x01eaefdbdaaee7421fc4d3ede5ffffffff"
+ },
+ "src": "8249:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4015,
+ "nodeType": "ExpressionStatement",
+ "src": "8249:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4020,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4016,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8315:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4018,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3937",
+ "id": 4017,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8328:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_97_by_1",
+ "typeString": "int_const 97"
+ },
+ "value": "97"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8315:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830316436626438623265623235376466376538636135376230396266666666666666",
+ "id": 4019,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8334:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_625721325079798489641586010116704960511_by_1",
+ "typeString": "int_const 6257...(31 digits omitted)...0511"
+ },
+ "value": "0x01d6bd8b2eb257df7e8ca57b09bfffffff"
+ },
+ "src": "8315:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4021,
+ "nodeType": "ExpressionStatement",
+ "src": "8315:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4026,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4022,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8381:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4024,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3938",
+ "id": 4023,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8394:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_98_by_1",
+ "typeString": "int_const 98"
+ },
+ "value": "98"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8381:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830316333356665646431346238363165623034343366376631333366666666666666",
+ "id": 4025,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8400:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_599979917813693414950432886451725139967_by_1",
+ "typeString": "int_const 5999...(31 digits omitted)...9967"
+ },
+ "value": "0x01c35fedd14b861eb0443f7f133fffffff"
+ },
+ "src": "8381:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4027,
+ "nodeType": "ExpressionStatement",
+ "src": "8381:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4032,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4028,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8447:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4030,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3939",
+ "id": 4029,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8460:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_99_by_1",
+ "typeString": "int_const 99"
+ },
+ "value": "99"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8447:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830316230636534336233323262636465346135366538616461356166666666666666",
+ "id": 4031,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8466:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_575297480445977184425850753341355720703_by_1",
+ "typeString": "int_const 5752...(31 digits omitted)...0703"
+ },
+ "value": "0x01b0ce43b322bcde4a56e8ada5afffffff"
+ },
+ "src": "8447:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4033,
+ "nodeType": "ExpressionStatement",
+ "src": "8447:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4038,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4034,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8513:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4036,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313030",
+ "id": 4035,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8525:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_100_by_1",
+ "typeString": "int_const 100"
+ },
+ "value": "100"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8513:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313966303032386563316666663030376635613139356133396466666666666666",
+ "id": 4037,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8532:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_551630448254872900425972804456347074559_by_1",
+ "typeString": "int_const 5516...(31 digits omitted)...4559"
+ },
+ "value": "0x019f0028ec1fff007f5a195a39dfffffff"
+ },
+ "src": "8513:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4039,
+ "nodeType": "ExpressionStatement",
+ "src": "8513:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4044,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4040,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8579:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4042,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313031",
+ "id": 4041,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8591:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_101_by_1",
+ "typeString": "int_const 101"
+ },
+ "value": "101"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8579:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313864656439316630653732656537346634396231356261353237666666666666",
+ "id": 4043,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8598:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_528937048717783628792119060092411707391_by_1",
+ "typeString": "int_const 5289...(31 digits omitted)...7391"
+ },
+ "value": "0x018ded91f0e72ee74f49b15ba527ffffff"
+ },
+ "src": "8579:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4045,
+ "nodeType": "ExpressionStatement",
+ "src": "8579:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4050,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4046,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8645:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4048,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313032",
+ "id": 4047,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8657:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_102_by_1",
+ "typeString": "int_const 102"
+ },
+ "value": "102"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8645:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313764386563376630343133366634653536313566643431613633666666666666",
+ "id": 4049,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8664:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_507177227782417987326846600868857380863_by_1",
+ "typeString": "int_const 5071...(31 digits omitted)...0863"
+ },
+ "value": "0x017d8ec7f04136f4e5615fd41a63ffffff"
+ },
+ "src": "8645:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4051,
+ "nodeType": "ExpressionStatement",
+ "src": "8645:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4056,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4052,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8711:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4054,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313033",
+ "id": 4053,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8723:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_103_by_1",
+ "typeString": "int_const 103"
+ },
+ "value": "103"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8711:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313664646336353536636462383462646338643132643232653666666666666666",
+ "id": 4055,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8730:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_486312579171031128343732298613950251007_by_1",
+ "typeString": "int_const 4863...(31 digits omitted)...1007"
+ },
+ "value": "0x016ddc6556cdb84bdc8d12d22e6fffffff"
+ },
+ "src": "8711:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4057,
+ "nodeType": "ExpressionStatement",
+ "src": "8711:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4062,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4058,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8777:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4060,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313034",
+ "id": 4059,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8789:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_104_by_1",
+ "typeString": "int_const 104"
+ },
+ "value": "104"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8777:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313565636635323737366131313535623562643833393538313466376666666666",
+ "id": 4061,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8796:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_466306276593002471003532891264408092671_by_1",
+ "typeString": "int_const 4663...(31 digits omitted)...2671"
+ },
+ "value": "0x015ecf52776a1155b5bd8395814f7fffff"
+ },
+ "src": "8777:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4063,
+ "nodeType": "ExpressionStatement",
+ "src": "8777:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4068,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4064,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8843:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4066,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313035",
+ "id": 4065,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8855:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_105_by_1",
+ "typeString": "int_const 105"
+ },
+ "value": "105"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8843:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313530363063323536636232336233623363633337353463663430666666666666",
+ "id": 4067,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8862:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_447123008746104779416515886102660251647_by_1",
+ "typeString": "int_const 4471...(31 digits omitted)...1647"
+ },
+ "value": "0x015060c256cb23b3b3cc3754cf40ffffff"
+ },
+ "src": "8843:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4069,
+ "nodeType": "ExpressionStatement",
+ "src": "8843:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4074,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4070,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8909:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4072,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313036",
+ "id": 4071,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8921:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_106_by_1",
+ "typeString": "int_const 106"
+ },
+ "value": "106"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8909:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313432386132663938643732386165323233646461623731356265336666666666",
+ "id": 4073,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8928:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_428728916991741247552240490495652921343_by_1",
+ "typeString": "int_const 4287...(31 digits omitted)...1343"
+ },
+ "value": "0x01428a2f98d728ae223ddab715be3fffff"
+ },
+ "src": "8909:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4075,
+ "nodeType": "ExpressionStatement",
+ "src": "8909:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4080,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4076,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "8975:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4078,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313037",
+ "id": 4077,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8987:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_107_by_1",
+ "typeString": "int_const 107"
+ },
+ "value": "107"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "8975:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313335343535393865356332333237366363663065646536383033346666666666",
+ "id": 4079,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "8994:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_411091535594146829344560212836376117247_by_1",
+ "typeString": "int_const 4110...(31 digits omitted)...7247"
+ },
+ "value": "0x013545598e5c23276ccf0ede68034fffff"
+ },
+ "src": "8975:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4081,
+ "nodeType": "ExpressionStatement",
+ "src": "8975:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4086,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4082,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9041:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4084,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313038",
+ "id": 4083,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9053:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_108_by_1",
+ "typeString": "int_const 108"
+ },
+ "value": "108"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9041:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313238386334313631636531643666353462376636313038313139346666666666",
+ "id": 4085,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9060:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_394179734418075472107167272299635146751_by_1",
+ "typeString": "int_const 3941...(31 digits omitted)...6751"
+ },
+ "value": "0x01288c4161ce1d6f54b7f61081194fffff"
+ },
+ "src": "9041:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4087,
+ "nodeType": "ExpressionStatement",
+ "src": "9041:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4092,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4088,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9107:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4090,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313039",
+ "id": 4089,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9119:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_109_by_1",
+ "typeString": "int_const 109"
+ },
+ "value": "109"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9107:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313163353932373631633636366161363431643561303161343066313766666666",
+ "id": 4091,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9126:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_377963663983834160889726215582593318911_by_1",
+ "typeString": "int_const 3779...(31 digits omitted)...8911"
+ },
+ "value": "0x011c592761c666aa641d5a01a40f17ffff"
+ },
+ "src": "9107:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4093,
+ "nodeType": "ExpressionStatement",
+ "src": "9107:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4098,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4094,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9173:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4096,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313130",
+ "id": 4095,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9185:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_110_by_1",
+ "typeString": "int_const 110"
+ },
+ "value": "110"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9173:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313130613638383638306137353330353135663365366536636664636466666666",
+ "id": 4097,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9192:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_362414702782685419520589203652335239167_by_1",
+ "typeString": "int_const 3624...(31 digits omitted)...9167"
+ },
+ "value": "0x0110a688680a7530515f3e6e6cfdcdffff"
+ },
+ "src": "9173:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4099,
+ "nodeType": "ExpressionStatement",
+ "src": "9173:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4104,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4100,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9239:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4102,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313131",
+ "id": 4101,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9251:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_111_by_1",
+ "typeString": "int_const 111"
+ },
+ "value": "111"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9239:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830313035366631623562656466373563366263623263653861656434323866666666",
+ "id": 4103,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9258:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_347505406759629484539078662328460836863_by_1",
+ "typeString": "int_const 3475...(31 digits omitted)...6863"
+ },
+ "value": "0x01056f1b5bedf75c6bcb2ce8aed428ffff"
+ },
+ "src": "9239:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4105,
+ "nodeType": "ExpressionStatement",
+ "src": "9239:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4110,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4106,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9305:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4108,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313132",
+ "id": 4107,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9317:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_112_by_1",
+ "typeString": "int_const 112"
+ },
+ "value": "112"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9305:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306661616463656365656666386130383930663338373566303038323737666666",
+ "id": 4109,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9324:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_333209460874402812645752271223906598911_by_1",
+ "typeString": "int_const 3332...(31 digits omitted)...8911"
+ },
+ "value": "0x00faadceceeff8a0890f3875f008277fff"
+ },
+ "src": "9305:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4111,
+ "nodeType": "ExpressionStatement",
+ "src": "9305:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4116,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4112,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9371:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4114,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313133",
+ "id": 4113,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9383:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_113_by_1",
+ "typeString": "int_const 113"
+ },
+ "value": "113"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9371:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306630356463366232376564616433303633383861363030663662613062666666",
+ "id": 4115,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9390:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_319501632655197652636411056021540225023_by_1",
+ "typeString": "int_const 3195...(31 digits omitted)...5023"
+ },
+ "value": "0x00f05dc6b27edad306388a600f6ba0bfff"
+ },
+ "src": "9371:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4117,
+ "nodeType": "ExpressionStatement",
+ "src": "9371:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4122,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4118,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9437:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4120,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313134",
+ "id": 4119,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9449:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_114_by_1",
+ "typeString": "int_const 114"
+ },
+ "value": "114"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9437:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306536376135613235646134313036336465313439356435623138636462666666",
+ "id": 4121,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9456:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_306357727663124583211687061200571318271_by_1",
+ "typeString": "int_const 3063...(31 digits omitted)...8271"
+ },
+ "value": "0x00e67a5a25da41063de1495d5b18cdbfff"
+ },
+ "src": "9437:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4123,
+ "nodeType": "ExpressionStatement",
+ "src": "9437:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4128,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4124,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9503:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4126,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313135",
+ "id": 4125,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9515:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_115_by_1",
+ "typeString": "int_const 115"
+ },
+ "value": "115"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9503:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306463666631313562313465656464653666633361613533353366326534666666",
+ "id": 4127,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9522:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_293754546788812396405978813098581970943_by_1",
+ "typeString": "int_const 2937...(31 digits omitted)...0943"
+ },
+ "value": "0x00dcff115b14eedde6fc3aa5353f2e4fff"
+ },
+ "src": "9503:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4129,
+ "nodeType": "ExpressionStatement",
+ "src": "9503:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4134,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4130,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9569:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4132,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313136",
+ "id": 4131,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9581:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_116_by_1",
+ "typeString": "int_const 116"
+ },
+ "value": "116"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9569:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306433653761333932343331323339396639616165326530663836386638666666",
+ "id": 4133,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9588:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_281669845305773445111617137421885345791_by_1",
+ "typeString": "int_const 2816...(31 digits omitted)...5791"
+ },
+ "value": "0x00d3e7a3924312399f9aae2e0f868f8fff"
+ },
+ "src": "9569:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4135,
+ "nodeType": "ExpressionStatement",
+ "src": "9569:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4140,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4136,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9635:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4138,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313137",
+ "id": 4137,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9647:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_117_by_1",
+ "typeString": "int_const 117"
+ },
+ "value": "117"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9635:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306362326666353239656237316534313538326363636435613165653236666666",
+ "id": 4139,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9654:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_270082293608263279864102872957453496319_by_1",
+ "typeString": "int_const 2700...(31 digits omitted)...6319"
+ },
+ "value": "0x00cb2ff529eb71e41582cccd5a1ee26fff"
+ },
+ "src": "9635:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4141,
+ "nodeType": "ExpressionStatement",
+ "src": "9635:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4146,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4142,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9701:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4144,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313138",
+ "id": 4143,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9713:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_118_by_1",
+ "typeString": "int_const 118"
+ },
+ "value": "118"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9701:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306332643431356333646239373461623332613531383430633062363765646666",
+ "id": 4145,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9720:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_258971439564336547476984432763364437503_by_1",
+ "typeString": "int_const 2589...(31 digits omitted)...7503"
+ },
+ "value": "0x00c2d415c3db974ab32a51840c0b67edff"
+ },
+ "src": "9701:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4147,
+ "nodeType": "ExpressionStatement",
+ "src": "9701:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4152,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4148,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9767:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4150,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313139",
+ "id": 4149,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9779:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_119_by_1",
+ "typeString": "int_const 119"
+ },
+ "value": "119"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9767:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306261643033653764383833663639616435623061313836313834653036626666",
+ "id": 4151,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9786:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_248317672417651959902117100034610719743_by_1",
+ "typeString": "int_const 2483...(31 digits omitted)...9743"
+ },
+ "value": "0x00bad03e7d883f69ad5b0a186184e06bff"
+ },
+ "src": "9767:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4153,
+ "nodeType": "ExpressionStatement",
+ "src": "9767:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4158,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4154,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9833:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4156,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313230",
+ "id": 4155,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9845:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_120_by_1",
+ "typeString": "int_const 120"
+ },
+ "value": "120"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9833:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306233323064303362326333343364343832396162643630373566306363356666",
+ "id": 4157,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9852:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_238102188174312697593221439720218478079_by_1",
+ "typeString": "int_const 2381...(31 digits omitted)...8079"
+ },
+ "value": "0x00b320d03b2c343d4829abd6075f0cc5ff"
+ },
+ "src": "9833:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4159,
+ "nodeType": "ExpressionStatement",
+ "src": "9833:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4164,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4160,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9899:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4162,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313231",
+ "id": 4161,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9911:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_121_by_1",
+ "typeString": "int_const 121"
+ },
+ "value": "121"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9899:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306162633235323034653032383238643733633665383062636462316139356266",
+ "id": 4163,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9918:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_228306956413649712418347768277622232511_by_1",
+ "typeString": "int_const 2283...(31 digits omitted)...2511"
+ },
+ "value": "0x00abc25204e02828d73c6e80bcdb1a95bf"
+ },
+ "src": "9899:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4165,
+ "nodeType": "ExpressionStatement",
+ "src": "9899:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4170,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4166,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "9965:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4168,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313232",
+ "id": 4167,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9977:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_122_by_1",
+ "typeString": "int_const 122"
+ },
+ "value": "122"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "9965:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830306134623136663734656534626232303430613165633663313566626266326466",
+ "id": 4169,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "9984:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_218914688464368667066255864092044292831_by_1",
+ "typeString": "int_const 2189...(31 digits omitted)...2831"
+ },
+ "value": "0x00a4b16f74ee4bb2040a1ec6c15fbbf2df"
+ },
+ "src": "9965:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4171,
+ "nodeType": "ExpressionStatement",
+ "src": "9965:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4176,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4172,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "10031:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4174,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313233",
+ "id": 4173,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10043:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_123_by_1",
+ "typeString": "int_const 123"
+ },
+ "value": "123"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10031:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830303964656166373336616331663536396465623162356165336633366331333066",
+ "id": 4175,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10050:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_209908806889891126870119775672831054607_by_1",
+ "typeString": "int_const 2099...(31 digits omitted)...4607"
+ },
+ "value": "0x009deaf736ac1f569deb1b5ae3f36c130f"
+ },
+ "src": "10031:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4177,
+ "nodeType": "ExpressionStatement",
+ "src": "10031:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4182,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4178,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "10097:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4180,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313234",
+ "id": 4179,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10109:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_124_by_1",
+ "typeString": "int_const 124"
+ },
+ "value": "124"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10097:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830303937366264393935326337616139353766353933376437393065663635303337",
+ "id": 4181,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10116:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_201273416229031359487226059686877220919_by_1",
+ "typeString": "int_const 2012...(31 digits omitted)...0919"
+ },
+ "value": "0x00976bd9952c7aa957f5937d790ef65037"
+ },
+ "src": "10097:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4183,
+ "nodeType": "ExpressionStatement",
+ "src": "10097:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4188,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4184,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "10163:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4186,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313235",
+ "id": 4185,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10175:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_125_by_1",
+ "typeString": "int_const 125"
+ },
+ "value": "125"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10163:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830303931333132373139323265616136303634623733613232643062643466326266",
+ "id": 4187,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10182:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_192993274940365776401274035698589299391_by_1",
+ "typeString": "int_const 1929...(31 digits omitted)...9391"
+ },
+ "value": "0x009131271922eaa6064b73a22d0bd4f2bf"
+ },
+ "src": "10163:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4189,
+ "nodeType": "ExpressionStatement",
+ "src": "10163:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4194,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4190,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "10229:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4192,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313236",
+ "id": 4191,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10241:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_126_by_1",
+ "typeString": "int_const 126"
+ },
+ "value": "126"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10229:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830303862333830663335353836363863343663393163343961326638653936376239",
+ "id": 4193,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10248:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_185053768500776578446843424638883162041_by_1",
+ "typeString": "int_const 1850...(31 digits omitted)...2041"
+ },
+ "value": "0x008b380f3558668c46c91c49a2f8e967b9"
+ },
+ "src": "10229:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4195,
+ "nodeType": "ExpressionStatement",
+ "src": "10229:55:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4200,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4196,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "10295:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4198,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313237",
+ "id": 4197,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10307:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_127_by_1",
+ "typeString": "int_const 127"
+ },
+ "value": "127"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10295:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "307830303835376464663031313765666132313539353239313238333966363437336536",
+ "id": 4199,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10314:36:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_177440883610688295304820354615089591270_by_1",
+ "typeString": "int_const 1774...(31 digits omitted)...1270"
+ },
+ "value": "0x00857ddf0117efa215952912839f6473e6"
+ },
+ "src": "10295:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4201,
+ "nodeType": "ExpressionStatement",
+ "src": "10295:55:7"
+ }
+ ]
+ },
+ "documentation": null,
+ "id": 4203,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "initMaxExpArray",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 3624,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "1891:2:7"
+ },
+ "returnParameters": {
+ "id": 3625,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "1902:0:7"
+ },
+ "scope": 8977,
+ "src": "1867:8491:7",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "constant": false,
+ "id": 4207,
+ "mutability": "mutable",
+ "name": "lambertArray",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8977,
+ "src": "10416:33:7",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 4204,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "10416:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4206,
+ "length": {
+ "argumentTypes": null,
+ "hexValue": "313238",
+ "id": 4205,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10424:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_128_by_1",
+ "typeString": "int_const 128"
+ },
+ "value": "128"
+ },
+ "nodeType": "ArrayTypeName",
+ "src": "10416:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage_ptr",
+ "typeString": "uint256[128]"
+ }
+ },
+ "value": null,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 4978,
+ "nodeType": "Block",
+ "src": "10492:8328:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4214,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4210,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "10503:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4212,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 4211,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10518:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10503:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783630653339336336386432306231626430396465616162633033373362396335",
+ "id": 4213,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10523:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_128787536227304155647383678419039664581_by_1",
+ "typeString": "int_const 1287...(31 digits omitted)...4581"
+ },
+ "value": "0x60e393c68d20b1bd09deaabc0373b9c5"
+ },
+ "src": "10503:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4215,
+ "nodeType": "ExpressionStatement",
+ "src": "10503:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4220,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4216,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "10568:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4218,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 4217,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10583:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10568:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783566386634366534383534313230393839656439343731396662346332303131",
+ "id": 4219,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10588:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_127020595924271037561532833511427022865_by_1",
+ "typeString": "int_const 1270...(31 digits omitted)...2865"
+ },
+ "value": "0x5f8f46e4854120989ed94719fb4c2011"
+ },
+ "src": "10568:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4221,
+ "nodeType": "ExpressionStatement",
+ "src": "10568:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4226,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4222,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "10633:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4224,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 4223,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10648:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10633:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783565343739656262393132396662316237653732613634386639393262363036",
+ "id": 4225,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10653:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_125319304162047910149801695424990590470_by_1",
+ "typeString": "int_const 1253...(31 digits omitted)...0470"
+ },
+ "value": "0x5e479ebb9129fb1b7e72a648f992b606"
+ },
+ "src": "10633:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4227,
+ "nodeType": "ExpressionStatement",
+ "src": "10633:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4232,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4228,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "10698:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4230,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "33",
+ "id": 4229,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10713:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3_by_1",
+ "typeString": "int_const 3"
+ },
+ "value": "3"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10698:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783564306264323366653432646665646465326539353836626531326238356665",
+ "id": 4231,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10718:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_123679583241450252008727309686047213054_by_1",
+ "typeString": "int_const 1236...(31 digits omitted)...3054"
+ },
+ "value": "0x5d0bd23fe42dfedde2e9586be12b85fe"
+ },
+ "src": "10698:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4233,
+ "nodeType": "ExpressionStatement",
+ "src": "10698:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4238,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4234,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "10763:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4236,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "34",
+ "id": 4235,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10778:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4_by_1",
+ "typeString": "int_const 4"
+ },
+ "value": "4"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10763:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783562646232396464656539373933303864646663613831616565623830393561",
+ "id": 4237,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10783:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_122097709790504811543485325791668472154_by_1",
+ "typeString": "int_const 1220...(31 digits omitted)...2154"
+ },
+ "value": "0x5bdb29ddee979308ddfca81aeeb8095a"
+ },
+ "src": "10763:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4239,
+ "nodeType": "ExpressionStatement",
+ "src": "10763:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4244,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4240,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "10828:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4242,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "35",
+ "id": 4241,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10843:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_5_by_1",
+ "typeString": "int_const 5"
+ },
+ "value": "5"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10828:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783561623466643861323630643263376532633064326166636630303039646164",
+ "id": 4243,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10848:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_120570275450071204896029314248949669293_by_1",
+ "typeString": "int_const 1205...(31 digits omitted)...9293"
+ },
+ "value": "0x5ab4fd8a260d2c7e2c0d2afcf0009dad"
+ },
+ "src": "10828:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4245,
+ "nodeType": "ExpressionStatement",
+ "src": "10828:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4250,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4246,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "10893:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4248,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "36",
+ "id": 4247,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10908:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6_by_1",
+ "typeString": "int_const 6"
+ },
+ "value": "6"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10893:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783539393862333133353961353564343837323463363563663039303031323231",
+ "id": 4249,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10913:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_119094152831753027058824439515169428001_by_1",
+ "typeString": "int_const 1190...(31 digits omitted)...8001"
+ },
+ "value": "0x5998b31359a55d48724c65cf09001221"
+ },
+ "src": "10893:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4251,
+ "nodeType": "ExpressionStatement",
+ "src": "10893:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4256,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4252,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "10958:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4254,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "37",
+ "id": 4253,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10973:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_7_by_1",
+ "typeString": "int_const 7"
+ },
+ "value": "7"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "10958:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783538383562636164326233323264666334336538383630663963303138636635",
+ "id": 4255,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10978:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_117666465924103849245162796602282314997_by_1",
+ "typeString": "int_const 1176...(31 digits omitted)...4997"
+ },
+ "value": "0x5885bcad2b322dfc43e8860f9c018cf5"
+ },
+ "src": "10958:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4257,
+ "nodeType": "ExpressionStatement",
+ "src": "10958:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4262,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4258,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11023:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4260,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "38",
+ "id": 4259,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11038:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_8_by_1",
+ "typeString": "int_const 8"
+ },
+ "value": "8"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11023:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783537376239376161316665323232626234353266646631313162316630626532",
+ "id": 4261,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11043:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_116284564269392660122793483482959907810_by_1",
+ "typeString": "int_const 1162...(31 digits omitted)...7810"
+ },
+ "value": "0x577b97aa1fe222bb452fdf111b1f0be2"
+ },
+ "src": "11023:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4263,
+ "nodeType": "ExpressionStatement",
+ "src": "11023:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4268,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4264,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11088:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4266,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "39",
+ "id": 4265,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11103:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_9_by_1",
+ "typeString": "int_const 9"
+ },
+ "value": "9"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11088:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783536373963623565333537353633326535626161323765326239343966373034",
+ "id": 4267,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11108:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_114946000350526915053586759724674184964_by_1",
+ "typeString": "int_const 1149...(31 digits omitted)...4964"
+ },
+ "value": "0x5679cb5e3575632e5baa27e2b949f704"
+ },
+ "src": "11088:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4269,
+ "nodeType": "ExpressionStatement",
+ "src": "11088:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4274,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4270,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11153:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4272,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3130",
+ "id": 4271,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11167:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_10_by_1",
+ "typeString": "int_const 10"
+ },
+ "value": "10"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11153:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783535376665383234316233613331633833633733326631636466663461316335",
+ "id": 4273,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11173:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_113648509722420118059077800055408992709_by_1",
+ "typeString": "int_const 1136...(31 digits omitted)...2709"
+ },
+ "value": "0x557fe8241b3a31c83c732f1cdff4a1c5"
+ },
+ "src": "11153:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4275,
+ "nodeType": "ExpressionStatement",
+ "src": "11153:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4280,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4276,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11218:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4278,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3131",
+ "id": 4277,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11232:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_11_by_1",
+ "typeString": "int_const 11"
+ },
+ "value": "11"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11218:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783534386438363830323635303438373564366535396262653935666332613662",
+ "id": 4279,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11238:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_112389993498935521792135674271903787627_by_1",
+ "typeString": "int_const 1123...(31 digits omitted)...7627"
+ },
+ "value": "0x548d868026504875d6e59bbe95fc2a6b"
+ },
+ "src": "11218:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4281,
+ "nodeType": "ExpressionStatement",
+ "src": "11218:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4286,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4282,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11283:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4284,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3132",
+ "id": 4283,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11297:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_12_by_1",
+ "typeString": "int_const 12"
+ },
+ "value": "12"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11283:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783533613234363563653334376366333464303561383637633137646433303838",
+ "id": 4285,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11303:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_111168502869233775922830736618948472968_by_1",
+ "typeString": "int_const 1111...(31 digits omitted)...2968"
+ },
+ "value": "0x53a2465ce347cf34d05a867c17dd3088"
+ },
+ "src": "11283:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4287,
+ "nodeType": "ExpressionStatement",
+ "src": "11283:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4292,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4288,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11348:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4290,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3133",
+ "id": 4289,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11362:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_13_by_1",
+ "typeString": "int_const 13"
+ },
+ "value": "13"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11348:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783532626463653564636434666165643539633766353531316366386638616363",
+ "id": 4291,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11368:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_109982225368764407855921799421290842828_by_1",
+ "typeString": "int_const 1099...(31 digits omitted)...2828"
+ },
+ "value": "0x52bdce5dcd4faed59c7f5511cf8f8acc"
+ },
+ "src": "11348:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4293,
+ "nodeType": "ExpressionStatement",
+ "src": "11348:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4298,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4294,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11413:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4296,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3134",
+ "id": 4295,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11427:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_14_by_1",
+ "typeString": "int_const 14"
+ },
+ "value": "14"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11413:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783531646663623435336330376638646138313736303665373838356637633365",
+ "id": 4297,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11433:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_108829472672502945287330645348712414270_by_1",
+ "typeString": "int_const 1088...(31 digits omitted)...4270"
+ },
+ "value": "0x51dfcb453c07f8da817606e7885f7c3e"
+ },
+ "src": "11413:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4299,
+ "nodeType": "ExpressionStatement",
+ "src": "11413:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4304,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4300,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11478:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4302,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3135",
+ "id": 4301,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11492:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_15_by_1",
+ "typeString": "int_const 15"
+ },
+ "value": "15"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11478:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783531303765663662306135613262653866386666313535393064616133636365",
+ "id": 4303,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11498:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_107708669713100452055447769980296903886_by_1",
+ "typeString": "int_const 1077...(31 digits omitted)...3886"
+ },
+ "value": "0x5107ef6b0a5a2be8f8ff15590daa3cce"
+ },
+ "src": "11478:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4305,
+ "nodeType": "ExpressionStatement",
+ "src": "11478:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4310,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4306,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11543:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4308,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3136",
+ "id": 4307,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11557:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_16_by_1",
+ "typeString": "int_const 16"
+ },
+ "value": "16"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11543:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783530333566323431643665616530636437626163626131313939393364653762",
+ "id": 4309,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11563:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_106618344955764005172185288135427743355_by_1",
+ "typeString": "int_const 1066...(31 digits omitted)...3355"
+ },
+ "value": "0x5035f241d6eae0cd7bacba119993de7b"
+ },
+ "src": "11543:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4311,
+ "nodeType": "ExpressionStatement",
+ "src": "11543:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4316,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4312,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11608:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4314,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3137",
+ "id": 4313,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11622:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_17_by_1",
+ "typeString": "int_const 17"
+ },
+ "value": "17"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11608:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783466363938666539306435623533643533323137316531323130313634633636",
+ "id": 4315,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11628:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_105557121686023412139304113347686190182_by_1",
+ "typeString": "int_const 1055...(31 digits omitted)...0182"
+ },
+ "value": "0x4f698fe90d5b53d532171e1210164c66"
+ },
+ "src": "11608:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4317,
+ "nodeType": "ExpressionStatement",
+ "src": "11608:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4322,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4318,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11673:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4320,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3138",
+ "id": 4319,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11687:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_18_by_1",
+ "typeString": "int_const 18"
+ },
+ "value": "18"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11673:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783465613238386361323937613065366130396130656565323430653136633835",
+ "id": 4321,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11693:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_104523710186937447092740323392662629509_by_1",
+ "typeString": "int_const 1045...(31 digits omitted)...9509"
+ },
+ "value": "0x4ea288ca297a0e6a09a0eee240e16c85"
+ },
+ "src": "11673:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4323,
+ "nodeType": "ExpressionStatement",
+ "src": "11673:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4328,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4324,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11738:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4326,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3139",
+ "id": 4325,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11752:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_19_by_1",
+ "typeString": "int_const 19"
+ },
+ "value": "19"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11738:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783464653061313366646366356434323133666333393862613665336265636465",
+ "id": 4327,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11758:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_103516900699454640661508604755841903838_by_1",
+ "typeString": "int_const 1035...(31 digits omitted)...3838"
+ },
+ "value": "0x4de0a13fdcf5d4213fc398ba6e3becde"
+ },
+ "src": "11738:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4329,
+ "nodeType": "ExpressionStatement",
+ "src": "11738:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4334,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4330,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11803:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4332,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3230",
+ "id": 4331,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11817:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_20_by_1",
+ "typeString": "int_const 20"
+ },
+ "value": "20"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11803:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783464323361313435656566393166656330366230363134303830346334383038",
+ "id": 4333,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11823:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_102535557074135248197607991940341319688_by_1",
+ "typeString": "int_const 1025...(31 digits omitted)...9688"
+ },
+ "value": "0x4d23a145eef91fec06b06140804c4808"
+ },
+ "src": "11803:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4335,
+ "nodeType": "ExpressionStatement",
+ "src": "11803:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4340,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4336,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11868:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4338,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3231",
+ "id": 4337,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11882:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_21_by_1",
+ "typeString": "int_const 21"
+ },
+ "value": "21"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11868:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783463366235343330643463316565353532363437336462346165306631316465",
+ "id": 4339,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11888:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_101578611034720610581211104132006351326_by_1",
+ "typeString": "int_const 1015...(31 digits omitted)...1326"
+ },
+ "value": "0x4c6b5430d4c1ee5526473db4ae0f11de"
+ },
+ "src": "11868:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4341,
+ "nodeType": "ExpressionStatement",
+ "src": "11868:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4346,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4342,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11933:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4344,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3232",
+ "id": 4343,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11947:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_22_by_1",
+ "typeString": "int_const 22"
+ },
+ "value": "22"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11933:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783462623738383663323430353632656261313166343936336135336234323430",
+ "id": 4345,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "11953:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_100645056984476184212709480501843018304_by_1",
+ "typeString": "int_const 1006...(31 digits omitted)...8304"
+ },
+ "value": "0x4bb7886c240562eba11f4963a53b4240"
+ },
+ "src": "11933:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4347,
+ "nodeType": "ExpressionStatement",
+ "src": "11933:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4352,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4348,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "11998:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4350,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3233",
+ "id": 4349,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12012:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_23_by_1",
+ "typeString": "int_const 23"
+ },
+ "value": "23"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "11998:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783462303830663366316362343931643264353231653065613435383335323165",
+ "id": 4351,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12018:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_99733947295139137817365771348103877150_by_1",
+ "typeString": "int_const 9973...(30 digits omitted)...7150"
+ },
+ "value": "0x4b080f3f1cb491d2d521e0ea4583521e"
+ },
+ "src": "11998:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4353,
+ "nodeType": "ExpressionStatement",
+ "src": "11998:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4358,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4354,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12063:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4356,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3234",
+ "id": 4355,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12077:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_24_by_1",
+ "typeString": "int_const 24"
+ },
+ "value": "24"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12063:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783461356362633936613035353839636234643836626531646233313638333634",
+ "id": 4357,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12083:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_98844388025919853370962885240683922276_by_1",
+ "typeString": "int_const 9884...(30 digits omitted)...2276"
+ },
+ "value": "0x4a5cbc96a05589cb4d86be1db3168364"
+ },
+ "src": "12063:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4359,
+ "nodeType": "ExpressionStatement",
+ "src": "12063:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4364,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4360,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12128:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4362,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3235",
+ "id": 4361,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12142:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_25_by_1",
+ "typeString": "int_const 25"
+ },
+ "value": "25"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12128:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783439623536366434303234333531373635386437386333333136326436656365",
+ "id": 4363,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12148:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_97975535026544040761524270664520658638_by_1",
+ "typeString": "int_const 9797...(30 digits omitted)...8638"
+ },
+ "value": "0x49b566d40243517658d78c33162d6ece"
+ },
+ "src": "12128:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4365,
+ "nodeType": "ExpressionStatement",
+ "src": "12128:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4370,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4366,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12193:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4368,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3236",
+ "id": 4367,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12207:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_26_by_1",
+ "typeString": "int_const 26"
+ },
+ "value": "26"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12193:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783439313165366130326535353037613330663934373338336664396133323736",
+ "id": 4369,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12213:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_97126590383947898169110886634107843190_by_1",
+ "typeString": "int_const 9712...(30 digits omitted)...3190"
+ },
+ "value": "0x4911e6a02e5507a30f947383fd9a3276"
+ },
+ "src": "12193:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4371,
+ "nodeType": "ExpressionStatement",
+ "src": "12193:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4376,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4372,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12258:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4374,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3237",
+ "id": 4373,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12272:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_27_by_1",
+ "typeString": "int_const 27"
+ },
+ "value": "27"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12258:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783438373231366332623331626534616463343164623861386435636330633838",
+ "id": 4375,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12278:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_96296799177093258962884240470124006536_by_1",
+ "typeString": "int_const 9629...(30 digits omitted)...6536"
+ },
+ "value": "0x487216c2b31be4adc41db8a8d5cc0c88"
+ },
+ "src": "12258:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4377,
+ "nodeType": "ExpressionStatement",
+ "src": "12258:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4382,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4378,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12323:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4380,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3238",
+ "id": 4379,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12337:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_28_by_1",
+ "typeString": "int_const 28"
+ },
+ "value": "28"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12323:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783437643564336663346137613162313838636433643738386235633565396663",
+ "id": 4381,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12343:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_95485446508569776991656929903084169724_by_1",
+ "typeString": "int_const 9548...(30 digits omitted)...9724"
+ },
+ "value": "0x47d5d3fc4a7a1b188cd3d788b5c5e9fc"
+ },
+ "src": "12323:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4383,
+ "nodeType": "ExpressionStatement",
+ "src": "12323:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4388,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4384,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12388:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4386,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3239",
+ "id": 4385,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12402:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_29_by_1",
+ "typeString": "int_const 29"
+ },
+ "value": "29"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12388:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783437336366636534383731613263343062633466396531633332623935356430",
+ "id": 4387,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12408:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_94691854785294407482575606759428806096_by_1",
+ "typeString": "int_const 9469...(30 digits omitted)...6096"
+ },
+ "value": "0x473cfce4871a2c40bc4f9e1c32b955d0"
+ },
+ "src": "12388:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4389,
+ "nodeType": "ExpressionStatement",
+ "src": "12388:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4394,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4390,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12453:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4392,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3330",
+ "id": 4391,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12467:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_30_by_1",
+ "typeString": "int_const 30"
+ },
+ "value": "30"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12453:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783436613737316361353738616238373834383538313065323835653331633637",
+ "id": 4393,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12473:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_93915381223786366589204098840684338279_by_1",
+ "typeString": "int_const 9391...(30 digits omitted)...8279"
+ },
+ "value": "0x46a771ca578ab878485810e285e31c67"
+ },
+ "src": "12453:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4395,
+ "nodeType": "ExpressionStatement",
+ "src": "12453:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4400,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4396,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12518:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4398,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3331",
+ "id": 4397,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12532:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_31_by_1",
+ "typeString": "int_const 31"
+ },
+ "value": "31"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12518:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783436313531343937313861656434633235386333373364633637366161373264",
+ "id": 4399,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12538:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_93155415558256953225873119289193178925_by_1",
+ "typeString": "int_const 9315...(30 digits omitted)...8925"
+ },
+ "value": "0x4615149718aed4c258c373dc676aa72d"
+ },
+ "src": "12518:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4401,
+ "nodeType": "ExpressionStatement",
+ "src": "12518:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4406,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4402,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12583:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4404,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3332",
+ "id": 4403,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12597:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_32_by_1",
+ "typeString": "int_const 32"
+ },
+ "value": "32"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12583:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783435383563386233663866653438396336653138333363613437383731333834",
+ "id": 4405,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12603:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_92411377932165840182246144520510444420_by_1",
+ "typeString": "int_const 9241...(30 digits omitted)...4420"
+ },
+ "value": "0x4585c8b3f8fe489c6e1833ca47871384"
+ },
+ "src": "12583:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4407,
+ "nodeType": "ExpressionStatement",
+ "src": "12583:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4412,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4408,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12648:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4410,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3333",
+ "id": 4409,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12662:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_33_by_1",
+ "typeString": "int_const 33"
+ },
+ "value": "33"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12648:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783434663937326631373465343165356566623765396436336332396365373335",
+ "id": 4411,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12668:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_91682716956007473314355351160117585717_by_1",
+ "typeString": "int_const 9168...(30 digits omitted)...5717"
+ },
+ "value": "0x44f972f174e41e5efb7e9d63c29ce735"
+ },
+ "src": "12648:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4413,
+ "nodeType": "ExpressionStatement",
+ "src": "12648:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4418,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4414,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12713:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4416,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3334",
+ "id": 4415,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12727:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_34_by_1",
+ "typeString": "int_const 34"
+ },
+ "value": "34"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12713:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783434366666393730626138366438623030626562303565636562663363346463",
+ "id": 4417,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12733:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_90968907915944387253011725111639917788_by_1",
+ "typeString": "int_const 9096...(30 digits omitted)...7788"
+ },
+ "value": "0x446ff970ba86d8b00beb05ecebf3c4dc"
+ },
+ "src": "12713:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4419,
+ "nodeType": "ExpressionStatement",
+ "src": "12713:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4424,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4420,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12778:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4422,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3335",
+ "id": 4421,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12792:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_35_by_1",
+ "typeString": "int_const 35"
+ },
+ "value": "35"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12778:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783433653934333865633838393731383132643666313938623563636161643936",
+ "id": 4423,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12798:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_90269451119533660821329652693370318230_by_1",
+ "typeString": "int_const 9026...(30 digits omitted)...8230"
+ },
+ "value": "0x43e9438ec88971812d6f198b5ccaad96"
+ },
+ "src": "12778:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4425,
+ "nodeType": "ExpressionStatement",
+ "src": "12778:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4430,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4426,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12843:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4428,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3336",
+ "id": 4427,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12857:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_36_by_1",
+ "typeString": "int_const 36"
+ },
+ "value": "36"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12843:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783433363533396431316666376265613635376165646462333934653830396566",
+ "id": 4429,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12863:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_89583870366228295001513378307654552047_by_1",
+ "typeString": "int_const 8958...(30 digits omitted)...2047"
+ },
+ "value": "0x436539d11ff7bea657aeddb394e809ef"
+ },
+ "src": "12843:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4431,
+ "nodeType": "ExpressionStatement",
+ "src": "12843:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4436,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4432,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12908:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4434,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3337",
+ "id": 4433,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12922:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_37_by_1",
+ "typeString": "int_const 37"
+ },
+ "value": "37"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12908:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783432653363356433653561393133343031643836663636646235643831633263",
+ "id": 4435,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12928:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_88911711531602529992461785625724984364_by_1",
+ "typeString": "int_const 8891...(30 digits omitted)...4364"
+ },
+ "value": "0x42e3c5d3e5a913401d86f66db5d81c2c"
+ },
+ "src": "12908:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4437,
+ "nodeType": "ExpressionStatement",
+ "src": "12908:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4442,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4438,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "12973:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4440,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3338",
+ "id": 4439,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12987:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_38_by_1",
+ "typeString": "int_const 38"
+ },
+ "value": "38"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "12973:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783432363464323339353330333037306561373236636265393864663632313734",
+ "id": 4441,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12993:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_88252541255370876457855407534749655412_by_1",
+ "typeString": "int_const 8825...(30 digits omitted)...5412"
+ },
+ "value": "0x4264d2395303070ea726cbe98df62174"
+ },
+ "src": "12973:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4443,
+ "nodeType": "ExpressionStatement",
+ "src": "12973:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4448,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4444,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13038:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4446,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3339",
+ "id": 4445,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13052:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_39_by_1",
+ "typeString": "int_const 39"
+ },
+ "value": "39"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13038:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783431653834613961353933626237313934633361363334396563616534656561",
+ "id": 4447,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13058:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_87605945724263666326070648659277401834_by_1",
+ "typeString": "int_const 8760...(30 digits omitted)...1834"
+ },
+ "value": "0x41e84a9a593bb7194c3a6349ecae4eea"
+ },
+ "src": "13038:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4449,
+ "nodeType": "ExpressionStatement",
+ "src": "13038:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4454,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4450,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13103:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4452,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3430",
+ "id": 4451,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13117:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_40_by_1",
+ "typeString": "int_const 40"
+ },
+ "value": "40"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13103:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783431366531623738356431336562613037613038663366313838373661356162",
+ "id": 4453,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13123:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_86971529541703351305061613312515941803_by_1",
+ "typeString": "int_const 8697...(30 digits omitted)...1803"
+ },
+ "value": "0x416e1b785d13eba07a08f3f18876a5ab"
+ },
+ "src": "13103:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4455,
+ "nodeType": "ExpressionStatement",
+ "src": "13103:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4460,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4456,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13168:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4458,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3431",
+ "id": 4457,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13182:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_41_by_1",
+ "typeString": "int_const 41"
+ },
+ "value": "41"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13168:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783430663633323266663338396434323362613964643765376537623765383039",
+ "id": 4459,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13188:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_86348914677009486241058826509159491593_by_1",
+ "typeString": "int_const 8634...(30 digits omitted)...1593"
+ },
+ "value": "0x40f6322ff389d423ba9dd7e7e7b7e809"
+ },
+ "src": "13168:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4461,
+ "nodeType": "ExpressionStatement",
+ "src": "13168:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4466,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4462,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13233:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4464,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3432",
+ "id": 4463,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13247:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_42_by_1",
+ "typeString": "int_const 42"
+ },
+ "value": "42"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13233:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783430383037636563386134363638383065636634313834353435643234306134",
+ "id": 4465,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13253:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_85737739487558329642902199100859629732_by_1",
+ "typeString": "int_const 8573...(30 digits omitted)...9732"
+ },
+ "value": "0x40807cec8a466880ecf4184545d240a4"
+ },
+ "src": "13233:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4467,
+ "nodeType": "ExpressionStatement",
+ "src": "13233:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4472,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4468,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13298:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4470,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3433",
+ "id": 4469,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13312:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_43_by_1",
+ "typeString": "int_const 43"
+ },
+ "value": "43"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13298:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783430306365613963653838613864336165363638653865613064396266303766",
+ "id": 4471,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13318:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_85137657807945661495348777847187304575_by_1",
+ "typeString": "int_const 8513...(30 digits omitted)...4575"
+ },
+ "value": "0x400cea9ce88a8d3ae668e8ea0d9bf07f"
+ },
+ "src": "13298:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4473,
+ "nodeType": "ExpressionStatement",
+ "src": "13298:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4478,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4474,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13363:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4476,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3434",
+ "id": 4475,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13377:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_44_by_1",
+ "typeString": "int_const 44"
+ },
+ "value": "44"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13363:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783366396236616538373732643463353530393165306564376466656130616331",
+ "id": 4477,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13383:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_84548338100757766960858976604962556609_by_1",
+ "typeString": "int_const 8454...(30 digits omitted)...6609"
+ },
+ "value": "0x3f9b6ae8772d4c55091e0ed7dfea0ac1"
+ },
+ "src": "13363:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4479,
+ "nodeType": "ExpressionStatement",
+ "src": "13363:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4484,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4480,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13428:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4482,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3435",
+ "id": 4481,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13442:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_45_by_1",
+ "typeString": "int_const 45"
+ },
+ "value": "45"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13428:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783366326265653235336664383435393466353462636161666163333833613133",
+ "id": 4483,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13448:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_83969462664053391893170430711084628499_by_1",
+ "typeString": "int_const 8396...(30 digits omitted)...8499"
+ },
+ "value": "0x3f2bee253fd84594f54bcaafac383a13"
+ },
+ "src": "13428:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4485,
+ "nodeType": "ExpressionStatement",
+ "src": "13428:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4490,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4486,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13493:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4488,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3436",
+ "id": 4487,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13507:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_46_by_1",
+ "typeString": "int_const 46"
+ },
+ "value": "46"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13493:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783365626536353465393532303862623932313063353735633038316335393538",
+ "id": 4489,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13513:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_83400726891105658214366213255032756568_by_1",
+ "typeString": "int_const 8340...(30 digits omitted)...6568"
+ },
+ "value": "0x3ebe654e95208bb9210c575c081c5958"
+ },
+ "src": "13493:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4491,
+ "nodeType": "ExpressionStatement",
+ "src": "13493:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4496,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4492,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13558:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4494,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3437",
+ "id": 4493,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13572:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_47_by_1",
+ "typeString": "int_const 47"
+ },
+ "value": "47"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13558:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783365353263316663353636353633356237386365316630356164353363303836",
+ "id": 4495,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13578:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_82841838578353379906637631327369937030_by_1",
+ "typeString": "int_const 8284...(30 digits omitted)...7030"
+ },
+ "value": "0x3e52c1fc5665635b78ce1f05ad53c086"
+ },
+ "src": "13558:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4497,
+ "nodeType": "ExpressionStatement",
+ "src": "13558:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4502,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4498,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13623:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4500,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3438",
+ "id": 4499,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13637:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_48_by_1",
+ "typeString": "int_const 48"
+ },
+ "value": "48"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13623:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783364653866363561633338383130316464663731386136663563316566663635",
+ "id": 4501,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13643:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_82292517277871139787215964642962505573_by_1",
+ "typeString": "int_const 8229...(30 digits omitted)...5573"
+ },
+ "value": "0x3de8f65ac388101ddf718a6f5c1eff65"
+ },
+ "src": "13623:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4503,
+ "nodeType": "ExpressionStatement",
+ "src": "13623:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4508,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4504,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13688:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4506,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3439",
+ "id": 4505,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13702:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_49_by_1",
+ "typeString": "int_const 49"
+ },
+ "value": "49"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13688:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783364383066353232643539626430623332386361303132646634636432643439",
+ "id": 4507,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13708:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_81752493690991422478947035708677500233_by_1",
+ "typeString": "int_const 8175...(30 digits omitted)...0233"
+ },
+ "value": "0x3d80f522d59bd0b328ca012df4cd2d49"
+ },
+ "src": "13688:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4509,
+ "nodeType": "ExpressionStatement",
+ "src": "13688:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4514,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4510,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13753:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4512,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3530",
+ "id": 4511,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13767:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_50_by_1",
+ "typeString": "int_const 50"
+ },
+ "value": "50"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13753:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783364316162313933313239656137326232333634386131363131363361383561",
+ "id": 4513,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13773:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_81221509100004039595242960659394308186_by_1",
+ "typeString": "int_const 8122...(30 digits omitted)...8186"
+ },
+ "value": "0x3d1ab193129ea72b23648a161163a85a"
+ },
+ "src": "13753:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4515,
+ "nodeType": "ExpressionStatement",
+ "src": "13753:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4520,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4516,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13818:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4518,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3531",
+ "id": 4517,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13832:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_51_by_1",
+ "typeString": "int_const 51"
+ },
+ "value": "51"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13818:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783363623631663638643332353736633133356239356366623533663736643735",
+ "id": 4519,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13838:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_80699314835121533818862589255787965813_by_1",
+ "typeString": "int_const 8069...(30 digits omitted)...5813"
+ },
+ "value": "0x3cb61f68d32576c135b95cfb53f76d75"
+ },
+ "src": "13818:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4521,
+ "nodeType": "ExpressionStatement",
+ "src": "13818:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4526,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4522,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13883:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4524,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3532",
+ "id": 4523,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13897:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_52_by_1",
+ "typeString": "int_const 52"
+ },
+ "value": "52"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13883:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783363353333326439663161616538353161333631396537376534636338343733",
+ "id": 4525,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13903:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_80185671774137293097540719362983101555_by_1",
+ "typeString": "int_const 8018...(30 digits omitted)...1555"
+ },
+ "value": "0x3c5332d9f1aae851a3619e77e4cc8473"
+ },
+ "src": "13883:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4527,
+ "nodeType": "ExpressionStatement",
+ "src": "13883:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4532,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4528,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "13948:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4530,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3533",
+ "id": 4529,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13962:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_53_by_1",
+ "typeString": "int_const 53"
+ },
+ "value": "53"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "13948:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783362663165303865646265326161313039653135323566363537353965663733",
+ "id": 4531,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "13968:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_79680349872418462454459890475122421619_by_1",
+ "typeString": "int_const 7968...(30 digits omitted)...1619"
+ },
+ "value": "0x3bf1e08edbe2aa109e1525f65759ef73"
+ },
+ "src": "13948:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4533,
+ "nodeType": "ExpressionStatement",
+ "src": "13948:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4538,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4534,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14013:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4536,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3534",
+ "id": 4535,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14027:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_54_by_1",
+ "typeString": "int_const 54"
+ },
+ "value": "54"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14013:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783362393231643963666631336661326331393737343661336466633439313866",
+ "id": 4537,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14033:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_79183127721070807958897168260236874127_by_1",
+ "typeString": "int_const 7918...(30 digits omitted)...4127"
+ },
+ "value": "0x3b921d9cff13fa2c197746a3dfc4918f"
+ },
+ "src": "14013:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4539,
+ "nodeType": "ExpressionStatement",
+ "src": "14013:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4544,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4540,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14078:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4542,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3535",
+ "id": 4541,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14092:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_55_by_1",
+ "typeString": "int_const 55"
+ },
+ "value": "55"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14078:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783362333364663831383931306266633161356165666238663633616532616334",
+ "id": 4543,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14098:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_78693792131289586075780460739283528388_by_1",
+ "typeString": "int_const 7869...(30 digits omitted)...8388"
+ },
+ "value": "0x3b33df818910bfc1a5aefb8f63ae2ac4"
+ },
+ "src": "14078:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4545,
+ "nodeType": "ExpressionStatement",
+ "src": "14078:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4550,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4546,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14143:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4548,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3536",
+ "id": 4547,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14157:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_56_by_1",
+ "typeString": "int_const 56"
+ },
+ "value": "56"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14143:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783361643731633163373765333466613332613966313834393637656363626636",
+ "id": 4549,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14163:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_78212137743071079621363404241290185718_by_1",
+ "typeString": "int_const 7821...(30 digits omitted)...5718"
+ },
+ "value": "0x3ad71c1c77e34fa32a9f184967eccbf6"
+ },
+ "src": "14143:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4551,
+ "nodeType": "ExpressionStatement",
+ "src": "14143:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4556,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4552,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14208:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4554,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3537",
+ "id": 4553,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14222:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_57_by_1",
+ "typeString": "int_const 57"
+ },
+ "value": "57"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14208:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783361376263396162663263356262353365326637333834613861313635323161",
+ "id": 4555,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14228:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_77737966656605443744883248223254630938_by_1",
+ "typeString": "int_const 7773...(30 digits omitted)...0938"
+ },
+ "value": "0x3a7bc9abf2c5bb53e2f7384a8a16521a"
+ },
+ "src": "14208:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4557,
+ "nodeType": "ExpressionStatement",
+ "src": "14208:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4562,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4558,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14273:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4560,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3538",
+ "id": 4559,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14287:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_58_by_1",
+ "typeString": "int_const 58"
+ },
+ "value": "58"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14273:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783361323164656337653736333639373833613638613063363338356131633537",
+ "id": 4561,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14293:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_77271088084804339940770953226756955223_by_1",
+ "typeString": "int_const 7727...(30 digits omitted)...5223"
+ },
+ "value": "0x3a21dec7e76369783a68a0c6385a1c57"
+ },
+ "src": "14273:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4563,
+ "nodeType": "ExpressionStatement",
+ "src": "14273:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4568,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4564,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14338:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4566,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3539",
+ "id": 4565,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14352:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_59_by_1",
+ "typeString": "int_const 59"
+ },
+ "value": "59"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14338:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783339633935323564653663396364663763316331353763613461376136656533",
+ "id": 4567,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14358:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_76811318025537837376498009672859152099_by_1",
+ "typeString": "int_const 7681...(30 digits omitted)...2099"
+ },
+ "value": "0x39c9525de6c9cdf7c1c157ca4a7a6ee3"
+ },
+ "src": "14338:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4569,
+ "nodeType": "ExpressionStatement",
+ "src": "14338:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4574,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4570,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14403:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4572,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3630",
+ "id": 4571,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14417:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_60_by_1",
+ "typeString": "int_const 60"
+ },
+ "value": "60"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14403:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783339373231626164336463383564313234306666303139306530616461616333",
+ "id": 4573,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14423:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_76358478952265398947834068366573546179_by_1",
+ "typeString": "int_const 7635...(30 digits omitted)...6179"
+ },
+ "value": "0x39721bad3dc85d1240ff0190e0adaac3"
+ },
+ "src": "14403:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4575,
+ "nodeType": "ExpressionStatement",
+ "src": "14403:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4580,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4576,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14468:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4578,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3631",
+ "id": 4577,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14482:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_61_by_1",
+ "typeString": "int_const 61"
+ },
+ "value": "61"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14468:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783339316333323433343464333234386630343639656232386464336437376530",
+ "id": 4579,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14488:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_75912399521846487627533653549497808864_by_1",
+ "typeString": "int_const 7591...(30 digits omitted)...8864"
+ },
+ "value": "0x391c324344d3248f0469eb28dd3d77e0"
+ },
+ "src": "14468:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4581,
+ "nodeType": "ExpressionStatement",
+ "src": "14468:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4586,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4582,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14533:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4584,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3632",
+ "id": 4583,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14547:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_62_by_1",
+ "typeString": "int_const 62"
+ },
+ "value": "62"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14533:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783338633738646637653363373936323739666234666638343339346162336461",
+ "id": 4585,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14553:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_75472914298408358042964121331947975642_by_1",
+ "typeString": "int_const 7547...(30 digits omitted)...5642"
+ },
+ "value": "0x38c78df7e3c796279fb4ff84394ab3da"
+ },
+ "src": "14533:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4587,
+ "nodeType": "ExpressionStatement",
+ "src": "14533:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4592,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4588,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14598:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4590,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3633",
+ "id": 4589,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14612:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_63_by_1",
+ "typeString": "int_const 63"
+ },
+ "value": "63"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14598:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783338373432366561343633386165396161653038303439643335353463323061",
+ "id": 4591,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14618:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_75039863492232771067353298784442696202_by_1",
+ "typeString": "int_const 7503...(30 digits omitted)...6202"
+ },
+ "value": "0x387426ea4638ae9aae08049d3554c20a"
+ },
+ "src": "14598:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4593,
+ "nodeType": "ExpressionStatement",
+ "src": "14598:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4598,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4594,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14663:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4596,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3634",
+ "id": 4595,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14677:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_64_by_1",
+ "typeString": "int_const 64"
+ },
+ "value": "64"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14663:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783338323166353764626432373633323536633161393962626432303531333738",
+ "id": 4597,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14683:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_74613092712700430304450998910501327736_by_1",
+ "typeString": "int_const 7461...(30 digits omitted)...7736"
+ },
+ "value": "0x3821f57dbd2763256c1a99bbd2051378"
+ },
+ "src": "14663:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4599,
+ "nodeType": "ExpressionStatement",
+ "src": "14663:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4604,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4600,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14728:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4602,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3635",
+ "id": 4601,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14742:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_65_by_1",
+ "typeString": "int_const 65"
+ },
+ "value": "65"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14728:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783337643066323536636234366138633932666636326662626566323839363938",
+ "id": 4603,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14748:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_74192452734402555957346115989134677656_by_1",
+ "typeString": "int_const 7419...(30 digits omitted)...7656"
+ },
+ "value": "0x37d0f256cb46a8c92ff62fbbef289698"
+ },
+ "src": "14728:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4605,
+ "nodeType": "ExpressionStatement",
+ "src": "14728:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4610,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4606,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14793:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4608,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3636",
+ "id": 4607,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14807:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_66_by_1",
+ "typeString": "int_const 66"
+ },
+ "value": "66"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14793:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783337383131363538353931666663376162646431666561663363656639623733",
+ "id": 4609,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14813:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_73777799275593782240843075749260794739_by_1",
+ "typeString": "int_const 7377...(30 digits omitted)...4739"
+ },
+ "value": "0x37811658591ffc7abdd1feaf3cef9b73"
+ },
+ "src": "14793:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4611,
+ "nodeType": "ExpressionStatement",
+ "src": "14793:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4616,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4612,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14858:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4614,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3637",
+ "id": 4613,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14872:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_67_by_1",
+ "typeString": "int_const 67"
+ },
+ "value": "67"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14858:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783337333235616131306539653832663764663066333830663739393731353462",
+ "id": 4615,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14878:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_73368992788220026735092049811183441227_by_1",
+ "typeString": "int_const 7336...(30 digits omitted)...1227"
+ },
+ "value": "0x37325aa10e9e82f7df0f380f7997154b"
+ },
+ "src": "14858:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4617,
+ "nodeType": "ExpressionStatement",
+ "src": "14858:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4622,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4618,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14923:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4620,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3638",
+ "id": 4619,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14937:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_68_by_1",
+ "typeString": "int_const 68"
+ },
+ "value": "68"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14923:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783336653462383838636662343038643837336239613830643433393331316336",
+ "id": 4621,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14943:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_72965898258809617135734979750291247558_by_1",
+ "typeString": "int_const 7296...(30 digits omitted)...7558"
+ },
+ "value": "0x36e4b888cfb408d873b9a80d439311c6"
+ },
+ "src": "14923:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4623,
+ "nodeType": "ExpressionStatement",
+ "src": "14923:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4628,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4624,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "14988:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4626,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3639",
+ "id": 4625,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15002:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_69_by_1",
+ "typeString": "int_const 69"
+ },
+ "value": "69"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "14988:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783336393832393965353966346262396465363435666339623038633634636361",
+ "id": 4627,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15008:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_72568385019566207677944681290529131722_by_1",
+ "typeString": "int_const 7256...(30 digits omitted)...1722"
+ },
+ "value": "0x3698299e59f4bb9de645fc9b08c64cca"
+ },
+ "src": "14988:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4629,
+ "nodeType": "ExpressionStatement",
+ "src": "14988:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4634,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4630,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15053:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4632,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3730",
+ "id": 4631,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15067:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_70_by_1",
+ "typeString": "int_const 70"
+ },
+ "value": "70"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15053:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783336346361376135303132636236303330323362353764643365626664353064",
+ "id": 4633,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15073:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_72176326569048265991235723170299237645_by_1",
+ "typeString": "int_const 7217...(30 digits omitted)...7645"
+ },
+ "value": "0x364ca7a5012cb603023b57dd3ebfd50d"
+ },
+ "src": "15053:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4635,
+ "nodeType": "ExpressionStatement",
+ "src": "15053:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4640,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4636,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15118:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4638,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3731",
+ "id": 4637,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15132:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_71_by_1",
+ "typeString": "int_const 71"
+ },
+ "value": "71"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15118:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783336303232633932383931356237373861623162303661616565376536316434",
+ "id": 4639,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15138:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_71789600401862514754895875938526847444_by_1",
+ "typeString": "int_const 7178...(30 digits omitted)...7444"
+ },
+ "value": "0x36022c928915b778ab1b06aaee7e61d4"
+ },
+ "src": "15118:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4641,
+ "nodeType": "ExpressionStatement",
+ "src": "15118:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4646,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4642,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15183:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4644,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3732",
+ "id": 4643,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15197:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_72_by_1",
+ "typeString": "int_const 72"
+ },
+ "value": "72"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15183:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783335623862323864316137336463323735303066666533353535396363303238",
+ "id": 4645,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15203:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_71408087846837990426587462311123664936_by_1",
+ "typeString": "int_const 7140...(30 digits omitted)...4936"
+ },
+ "value": "0x35b8b28d1a73dc27500ffe35559cc028"
+ },
+ "src": "15183:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4647,
+ "nodeType": "ExpressionStatement",
+ "src": "15183:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4652,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4648,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15248:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4650,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3733",
+ "id": 4649,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15262:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_73_by_1",
+ "typeString": "int_const 73"
+ },
+ "value": "73"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15248:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783335373033336539353166653235306563356562346536303935353133326437",
+ "id": 4651,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15268:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_71031673913183621970866398796903953111_by_1",
+ "typeString": "int_const 7103...(30 digits omitted)...3111"
+ },
+ "value": "0x357033e951fe250ec5eb4e60955132d7"
+ },
+ "src": "15248:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4653,
+ "nodeType": "ExpressionStatement",
+ "src": "15248:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4658,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4654,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15313:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4656,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3734",
+ "id": 4655,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15327:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_74_by_1",
+ "typeString": "int_const 74"
+ },
+ "value": "74"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15313:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783335323861623238363739333465336132316235343132653463346638383831",
+ "id": 4657,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15333:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_70660247144165696899266624685710739585_by_1",
+ "typeString": "int_const 7066...(30 digits omitted)...9585"
+ },
+ "value": "0x3528ab2867934e3a21b5412e4c4f8881"
+ },
+ "src": "15313:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4659,
+ "nodeType": "ExpressionStatement",
+ "src": "15313:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4664,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4660,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15378:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4662,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3735",
+ "id": 4661,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15392:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_75_by_1",
+ "typeString": "int_const 75"
+ },
+ "value": "75"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15378:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783334653231326636366335353035376639363736633830303934613631643539",
+ "id": 4663,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15398:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_70293699477872506394924034036542610777_by_1",
+ "typeString": "int_const 7029...(30 digits omitted)...0777"
+ },
+ "value": "0x34e212f66c55057f9676c80094a61d59"
+ },
+ "src": "15378:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4665,
+ "nodeType": "ExpressionStatement",
+ "src": "15378:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4670,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4666,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15443:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4668,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3736",
+ "id": 4667,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15457:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_76_by_1",
+ "typeString": "int_const 76"
+ },
+ "value": "76"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15443:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783334396336363238396535623363346235343063323466343266613462396262",
+ "id": 4669,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15463:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_69931926114662060074913956973764721083_by_1",
+ "typeString": "int_const 6993...(30 digits omitted)...1083"
+ },
+ "value": "0x349c66289e5b3c4b540c24f42fa4b9bb"
+ },
+ "src": "15443:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4671,
+ "nodeType": "ExpressionStatement",
+ "src": "15443:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4676,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4672,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15508:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4674,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3737",
+ "id": 4673,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15522:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_77_by_1",
+ "typeString": "int_const 77"
+ },
+ "value": "77"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15508:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783334353739666262643063373333613963386436616636623066376430306637",
+ "id": 4675,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15528:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_69574825390915228431314065557192245495_by_1",
+ "typeString": "int_const 6957...(30 digits omitted)...5495"
+ },
+ "value": "0x34579fbbd0c733a9c8d6af6b0f7d00f7"
+ },
+ "src": "15508:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4677,
+ "nodeType": "ExpressionStatement",
+ "src": "15508:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4682,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4678,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15573:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4680,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3738",
+ "id": 4679,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15587:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_78_by_1",
+ "typeString": "int_const 78"
+ },
+ "value": "78"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15573:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783334313362616432653731323238386239323462353838326235623336396266",
+ "id": 4681,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15593:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_69222298658741183724931927301015431615_by_1",
+ "typeString": "int_const 6922...(30 digits omitted)...1615"
+ },
+ "value": "0x3413bad2e712288b924b5882b5b369bf"
+ },
+ "src": "15573:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4683,
+ "nodeType": "ExpressionStatement",
+ "src": "15573:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4688,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4684,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15638:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4686,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3739",
+ "id": 4685,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15652:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_79_by_1",
+ "typeString": "int_const 79"
+ },
+ "value": "79"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15638:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783333643062326235363238363531306566373330653231336637316631326539",
+ "id": 4687,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15658:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_68874250171304728554080761972223054569_by_1",
+ "typeString": "int_const 6887...(30 digits omitted)...4569"
+ },
+ "value": "0x33d0b2b56286510ef730e213f71f12e9"
+ },
+ "src": "15638:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4689,
+ "nodeType": "ExpressionStatement",
+ "src": "15638:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4694,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4690,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15703:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4692,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3830",
+ "id": 4691,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15717:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_80_by_1",
+ "typeString": "int_const 80"
+ },
+ "value": "80"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15703:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783333386538326365303065323439363236326336343435373533356261316131",
+ "id": 4693,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15723:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_68530586973466171479838674269845037473_by_1",
+ "typeString": "int_const 6853...(30 digits omitted)...7473"
+ },
+ "value": "0x338e82ce00e2496262c64457535ba1a1"
+ },
+ "src": "15703:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4695,
+ "nodeType": "ExpressionStatement",
+ "src": "15703:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4700,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4696,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15768:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4698,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3831",
+ "id": 4697,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15782:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_81_by_1",
+ "typeString": "int_const 81"
+ },
+ "value": "81"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15768:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783333346432366139366233373362623763326638656131383237663237613932",
+ "id": 4699,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15788:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_68191218797443963900028789779252542098_by_1",
+ "typeString": "int_const 6819...(30 digits omitted)...2098"
+ },
+ "value": "0x334d26a96b373bb7c2f8ea1827f27a92"
+ },
+ "src": "15768:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4701,
+ "nodeType": "ExpressionStatement",
+ "src": "15768:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4706,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4702,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15833:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4704,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3832",
+ "id": 4703,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15847:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_82_by_1",
+ "typeString": "int_const 82"
+ },
+ "value": "82"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15833:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783333306339396634663432313134363965303062336531386333313437356561",
+ "id": 4705,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15853:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_67856057963228472984547093013750642154_by_1",
+ "typeString": "int_const 6785...(30 digits omitted)...2154"
+ },
+ "value": "0x330c99f4f4211469e00b3e18c31475ea"
+ },
+ "src": "15833:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4707,
+ "nodeType": "ExpressionStatement",
+ "src": "15833:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4712,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4708,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15898:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4710,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3833",
+ "id": 4709,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15912:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_83_by_1",
+ "typeString": "int_const 83"
+ },
+ "value": "83"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15898:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783332636364383764363438363039343939396337643565366633333233376438",
+ "id": 4711,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15918:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_67525019283492142426218937050010367960_by_1",
+ "typeString": "int_const 6752...(30 digits omitted)...7960"
+ },
+ "value": "0x32ccd87d6486094999c7d5e6f33237d8"
+ },
+ "src": "15898:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4713,
+ "nodeType": "ExpressionStatement",
+ "src": "15898:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4718,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4714,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "15963:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4716,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3834",
+ "id": 4715,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15977:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_84_by_1",
+ "typeString": "int_const 84"
+ },
+ "value": "84"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "15963:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783332386464653264643631376236363635613265383535366632353063316166",
+ "id": 4717,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "15983:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_67198019972756986907927497888446333359_by_1",
+ "typeString": "int_const 6719...(30 digits omitted)...3359"
+ },
+ "value": "0x328dde2dd617b6665a2e8556f250c1af"
+ },
+ "src": "15963:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4719,
+ "nodeType": "ExpressionStatement",
+ "src": "15963:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4724,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4720,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16028:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4722,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3835",
+ "id": 4721,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16042:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_85_by_1",
+ "typeString": "int_const 85"
+ },
+ "value": "85"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16028:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783332346661373065396164633237306638323632373535616635613939616639",
+ "id": 4723,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16048:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_66874979560594969707697340554641251065_by_1",
+ "typeString": "int_const 6687...(30 digits omitted)...1065"
+ },
+ "value": "0x324fa70e9adc270f8262755af5a99af9"
+ },
+ "src": "16028:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4725,
+ "nodeType": "ExpressionStatement",
+ "src": "16028:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4730,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4726,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16093:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4728,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3836",
+ "id": 4727,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16107:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_86_by_1",
+ "typeString": "int_const 86"
+ },
+ "value": "86"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16093:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783332313232663434333131303631316361353130343066343166613665316533",
+ "id": 4729,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16113:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_66555819808650410033300276716637708771_by_1",
+ "typeString": "int_const 6655...(30 digits omitted)...8771"
+ },
+ "value": "0x32122f443110611ca51040f41fa6e1e3"
+ },
+ "src": "16093:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4731,
+ "nodeType": "ExpressionStatement",
+ "src": "16093:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4736,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4732,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16158:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4734,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3837",
+ "id": 4733,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16172:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_87_by_1",
+ "typeString": "int_const 87"
+ },
+ "value": "87"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16158:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783331643537333065343263303833313438326630663134383563343236336438",
+ "id": 4735,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16178:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_66240464631286234612917249162896106456_by_1",
+ "typeString": "int_const 6624...(30 digits omitted)...6456"
+ },
+ "value": "0x31d5730e42c0831482f0f1485c4263d8"
+ },
+ "src": "16158:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4737,
+ "nodeType": "ExpressionStatement",
+ "src": "16158:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4742,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4738,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16223:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4740,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3838",
+ "id": 4739,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16237:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_88_by_1",
+ "typeString": "int_const 88"
+ },
+ "value": "88"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16223:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783331393936656336623037623461383334323162356562633461623465316631",
+ "id": 4741,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16243:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_65928840019667697388313232298873250289_by_1",
+ "typeString": "int_const 6592...(30 digits omitted)...0289"
+ },
+ "value": "0x31996ec6b07b4a83421b5ebc4ab4e1f1"
+ },
+ "src": "16223:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4743,
+ "nodeType": "ExpressionStatement",
+ "src": "16223:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4748,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4744,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16288:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4746,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3839",
+ "id": 4745,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16302:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_89_by_1",
+ "typeString": "int_const 89"
+ },
+ "value": "89"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16288:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783331356531656530613638666634366262343365633262383530333265383736",
+ "id": 4747,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16308:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_65620873969108206581452393912976205942_by_1",
+ "typeString": "int_const 6562...(30 digits omitted)...5942"
+ },
+ "value": "0x315e1ee0a68ff46bb43ec2b85032e876"
+ },
+ "src": "16288:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4749,
+ "nodeType": "ExpressionStatement",
+ "src": "16288:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4754,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4750,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16353:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4752,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3930",
+ "id": 4751,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16367:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_90_by_1",
+ "typeString": "int_const 90"
+ },
+ "value": "90"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16353:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783331323337666537626334646561636636373735623965666131613134356638",
+ "id": 4753,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16373:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_65316496409512179290702222053435590136_by_1",
+ "typeString": "int_const 6531...(30 digits omitted)...0136"
+ },
+ "value": "0x31237fe7bc4deacf6775b9efa1a145f8"
+ },
+ "src": "16353:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4755,
+ "nodeType": "ExpressionStatement",
+ "src": "16353:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4760,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4756,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16418:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4758,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3931",
+ "id": 4757,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16432:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_91_by_1",
+ "typeString": "int_const 91"
+ },
+ "value": "91"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16418:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783330653938653766316363356133353665343436323761363937326561326666",
+ "id": 4759,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16438:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_65015639138759444595668739676303172351_by_1",
+ "typeString": "int_const 6501...(30 digits omitted)...2351"
+ },
+ "value": "0x30e98e7f1cc5a356e44627a6972ea2ff"
+ },
+ "src": "16418:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4761,
+ "nodeType": "ExpressionStatement",
+ "src": "16418:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4766,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4762,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16483:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4764,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3932",
+ "id": 4763,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16497:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_92_by_1",
+ "typeString": "int_const 92"
+ },
+ "value": "92"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16483:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783330623034373630623839313765633734323035613330303236353065633035",
+ "id": 4765,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16503:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_64718235758884686944788529404074585093_by_1",
+ "typeString": "int_const 6471...(30 digits omitted)...5093"
+ },
+ "value": "0x30b04760b8917ec74205a3002650ec05"
+ },
+ "src": "16483:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4767,
+ "nodeType": "ExpressionStatement",
+ "src": "16483:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4772,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4768,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16548:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4770,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3933",
+ "id": 4769,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16562:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_93_by_1",
+ "typeString": "int_const 93"
+ },
+ "value": "93"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16548:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783330373761373563383033343638653931333263653063663332323432343164",
+ "id": 4771,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16568:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_64424221614913808353797169251126354973_by_1",
+ "typeString": "int_const 6442...(30 digits omitted)...4973"
+ },
+ "value": "0x3077a75c803468e9132ce0cf3224241d"
+ },
+ "src": "16548:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4773,
+ "nodeType": "ExpressionStatement",
+ "src": "16548:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4778,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4774,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16613:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4776,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3934",
+ "id": 4775,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16627:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_94_by_1",
+ "typeString": "int_const 94"
+ },
+ "value": "94"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16613:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783330336661623537613661323735633336663139636461396261636536363761",
+ "id": 4777,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16633:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_64133533736226932951740123178454640250_by_1",
+ "typeString": "int_const 6413...(30 digits omitted)...0250"
+ },
+ "value": "0x303fab57a6a275c36f19cda9bace667a"
+ },
+ "src": "16613:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4779,
+ "nodeType": "ExpressionStatement",
+ "src": "16613:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4784,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4780,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16678:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4782,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3935",
+ "id": 4781,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16692:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_95_by_1",
+ "typeString": "int_const 95"
+ },
+ "value": "95"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16678:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783330303835303462656238646362643263663362633166366435613036346630",
+ "id": 4783,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16698:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_63846110780325119601596992296297981168_by_1",
+ "typeString": "int_const 6384...(30 digits omitted)...1168"
+ },
+ "value": "0x3008504beb8dcbd2cf3bc1f6d5a064f0"
+ },
+ "src": "16678:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4785,
+ "nodeType": "ExpressionStatement",
+ "src": "16678:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4790,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4786,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16743:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4788,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3936",
+ "id": 4787,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16757:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_96_by_1",
+ "typeString": "int_const 96"
+ },
+ "value": "96"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16743:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783266643139333436656431376461633631323139636530633263356163346230",
+ "id": 4789,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16763:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_63561892978884723546060567414717465776_by_1",
+ "typeString": "int_const 6356...(30 digits omitted)...5776"
+ },
+ "value": "0x2fd19346ed17dac61219ce0c2c5ac4b0"
+ },
+ "src": "16743:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4791,
+ "nodeType": "ExpressionStatement",
+ "src": "16743:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4796,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4792,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16808:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4794,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3937",
+ "id": 4793,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16822:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_97_by_1",
+ "typeString": "int_const 97"
+ },
+ "value": "97"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16808:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783266396237313639383038633332346235383532666433643534626139373134",
+ "id": 4795,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16828:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_63280822085989789325487105680707589908_by_1",
+ "typeString": "int_const 6328...(30 digits omitted)...9908"
+ },
+ "value": "0x2f9b7169808c324b5852fd3d54ba9714"
+ },
+ "src": "16808:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4797,
+ "nodeType": "ExpressionStatement",
+ "src": "16808:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4802,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4798,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16873:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4800,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3938",
+ "id": 4799,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16887:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_98_by_1",
+ "typeString": "int_const 98"
+ },
+ "value": "98"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16873:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783266363565376537313163663462303634656561396330386362646164353734",
+ "id": 4801,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16893:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_63002841328438895053366731000363275636_by_1",
+ "typeString": "int_const 6300...(30 digits omitted)...5636"
+ },
+ "value": "0x2f65e7e711cf4b064eea9c08cbdad574"
+ },
+ "src": "16873:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4803,
+ "nodeType": "ExpressionStatement",
+ "src": "16873:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4808,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4804,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "16938:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4806,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "3939",
+ "id": 4805,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16952:2:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_99_by_1",
+ "typeString": "int_const 99"
+ },
+ "value": "99"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "16938:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783266333066343035303933303432646466663861323531623662663664313033",
+ "id": 4807,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16958:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_62727895358028530630619015085479612675_by_1",
+ "typeString": "int_const 6272...(30 digits omitted)...2675"
+ },
+ "value": "0x2f30f405093042ddff8a251b6bf6d103"
+ },
+ "src": "16938:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4809,
+ "nodeType": "ExpressionStatement",
+ "src": "16938:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4814,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4810,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17003:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4812,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313030",
+ "id": 4811,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17016:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_100_by_1",
+ "typeString": "int_const 100"
+ },
+ "value": "100"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17003:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783265666339333161333735306632653862666533323365646665303337353734",
+ "id": 4813,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17023:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_62455930205720405594293470980571624820_by_1",
+ "typeString": "int_const 6245...(30 digits omitted)...4820"
+ },
+ "value": "0x2efc931a3750f2e8bfe323edfe037574"
+ },
+ "src": "17003:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4815,
+ "nodeType": "ExpressionStatement",
+ "src": "17003:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4820,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4816,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17068:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4818,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313031",
+ "id": 4817,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17081:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_101_by_1",
+ "typeString": "int_const 101"
+ },
+ "value": "101"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17068:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783265633863323865343664626535366439383638353237383333393430306362",
+ "id": 4819,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17088:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_62186893237605070014470966239378538699_by_1",
+ "typeString": "int_const 6218...(30 digits omitted)...8699"
+ },
+ "value": "0x2ec8c28e46dbe56d98685278339400cb"
+ },
+ "src": "17068:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4821,
+ "nodeType": "ExpressionStatement",
+ "src": "17068:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4826,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4822,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17133:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4824,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313032",
+ "id": 4823,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17146:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_102_by_1",
+ "typeString": "int_const 102"
+ },
+ "value": "102"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17133:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783265393537666439333363333932366438613539396236303233373962383531",
+ "id": 4825,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17153:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_61920733112578916349615492109849704529_by_1",
+ "typeString": "int_const 6192...(30 digits omitted)...4529"
+ },
+ "value": "0x2e957fd933c3926d8a599b602379b851"
+ },
+ "src": "17133:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4827,
+ "nodeType": "ExpressionStatement",
+ "src": "17133:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4832,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4828,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17198:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4830,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313033",
+ "id": 4829,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17211:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_103_by_1",
+ "typeString": "int_const 103"
+ },
+ "value": "103"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17198:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783265363263383832633763396564343437333431323730326630386261306535",
+ "id": 4831,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17218:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_61657399741656031957349998364069699813_by_1",
+ "typeString": "int_const 6165...(30 digits omitted)...9813"
+ },
+ "value": "0x2e62c882c7c9ed4473412702f08ba0e5"
+ },
+ "src": "17198:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4833,
+ "nodeType": "ExpressionStatement",
+ "src": "17198:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4838,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4834,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17263:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4836,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313034",
+ "id": 4835,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17276:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_104_by_1",
+ "typeString": "int_const 104"
+ },
+ "value": "104"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17263:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783265333039613232316331326261333631653365643639353136376665656532",
+ "id": 4837,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17283:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_61396844248840510020197488843164741346_by_1",
+ "typeString": "int_const 6139...(30 digits omitted)...1346"
+ },
+ "value": "0x2e309a221c12ba361e3ed695167feee2"
+ },
+ "src": "17263:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4839,
+ "nodeType": "ExpressionStatement",
+ "src": "17263:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4844,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4840,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17328:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4842,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313035",
+ "id": 4841,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17341:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_105_by_1",
+ "typeString": "int_const 105"
+ },
+ "value": "105"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17328:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783264666566323564316638363561653138646430376366656134626365613130",
+ "id": 4843,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17348:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_61139018933488718567153792494864230928_by_1",
+ "typeString": "int_const 6113...(30 digits omitted)...0928"
+ },
+ "value": "0x2dfef25d1f865ae18dd07cfea4bcea10"
+ },
+ "src": "17328:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4845,
+ "nodeType": "ExpressionStatement",
+ "src": "17328:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4850,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4846,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17393:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4848,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313036",
+ "id": 4847,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17406:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_106_by_1",
+ "typeString": "int_const 106"
+ },
+ "value": "106"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17393:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783264636463656538323163646338306465636330326334343334346165623331",
+ "id": 4849,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17413:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_60883877234094689345243041491992636209_by_1",
+ "typeString": "int_const 6088...(30 digits omitted)...6209"
+ },
+ "value": "0x2dcdcee821cdc80decc02c44344aeb31"
+ },
+ "src": "17393:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4851,
+ "nodeType": "ExpressionStatement",
+ "src": "17393:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4856,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4852,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17458:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4854,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313037",
+ "id": 4853,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17471:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_107_by_1",
+ "typeString": "int_const 107"
+ },
+ "value": "107"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17458:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783264396432643835363262333439343464306232303162623837323630633833",
+ "id": 4855,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17478:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_60631373693435235627049349068288822403_by_1",
+ "typeString": "int_const 6063...(30 digits omitted)...2403"
+ },
+ "value": "0x2d9d2d8562b34944d0b201bb87260c83"
+ },
+ "src": "17458:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4857,
+ "nodeType": "ExpressionStatement",
+ "src": "17458:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4862,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4858,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17523:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4860,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313038",
+ "id": 4859,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17536:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_108_by_1",
+ "typeString": "int_const 108"
+ },
+ "value": "108"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17523:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783264366430633034613562363261326334323633363330383636396237323961",
+ "id": 4861,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17543:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_60381463925014654644808174288326324890_by_1",
+ "typeString": "int_const 6038...(30 digits omitted)...4890"
+ },
+ "value": "0x2d6d0c04a5b62a2c42636308669b729a"
+ },
+ "src": "17523:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4863,
+ "nodeType": "ExpressionStatement",
+ "src": "17523:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4868,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4864,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17588:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4866,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313039",
+ "id": 4865,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17601:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_109_by_1",
+ "typeString": "int_const 109"
+ },
+ "value": "109"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17588:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783264336436383432633961323335353137666335613033333236393135323866",
+ "id": 4867,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17608:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_60134104580751929226866781633165480591_by_1",
+ "typeString": "int_const 6013...(30 digits omitted)...0591"
+ },
+ "value": "0x2d3d6842c9a235517fc5a0332691528f"
+ },
+ "src": "17588:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4869,
+ "nodeType": "ExpressionStatement",
+ "src": "17588:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4874,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4870,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17653:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4872,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313130",
+ "id": 4871,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17666:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_110_by_1",
+ "typeString": "int_const 110"
+ },
+ "value": "110"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17653:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783264306534303239363366653165613238333461626334303863343337633130",
+ "id": 4873,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17673:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_59889253319856226458538603217703631888_by_1",
+ "typeString": "int_const 5988...(30 digits omitted)...1888"
+ },
+ "value": "0x2d0e402963fe1ea2834abc408c437c10"
+ },
+ "src": "17653:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4875,
+ "nodeType": "ExpressionStatement",
+ "src": "17653:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4880,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4876,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17718:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4878,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313131",
+ "id": 4877,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17731:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_111_by_1",
+ "typeString": "int_const 111"
+ },
+ "value": "111"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17718:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783263646639316165363032363437393038616666393735653464366132613863",
+ "id": 4879,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17738:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_59646868778839210021497828354615290508_by_1",
+ "typeString": "int_const 5964...(30 digits omitted)...0508"
+ },
+ "value": "0x2cdf91ae602647908aff975e4d6a2a8c"
+ },
+ "src": "17718:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4881,
+ "nodeType": "ExpressionStatement",
+ "src": "17718:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4886,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4882,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17783:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4884,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313132",
+ "id": 4883,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17796:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_112_by_1",
+ "typeString": "int_const 112"
+ },
+ "value": "112"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17783:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783263623135616433613165623635663664373461373564613039613162366335",
+ "id": 4885,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17803:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_59406910542615247719403943326214371013_by_1",
+ "typeString": "int_const 5940...(30 digits omitted)...1013"
+ },
+ "value": "0x2cb15ad3a1eb65f6d74a75da09a1b6c5"
+ },
+ "src": "17783:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4887,
+ "nodeType": "ExpressionStatement",
+ "src": "17783:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4892,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4888,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17848:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4890,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313133",
+ "id": 4889,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17861:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_113_by_1",
+ "typeString": "int_const 113"
+ },
+ "value": "113"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17848:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783263383339396136616238653937373464366663666633373364323130373237",
+ "id": 4891,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17868:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_59169339116643016279047957521648125735_by_1",
+ "typeString": "int_const 5916...(30 digits omitted)...5735"
+ },
+ "value": "0x2c8399a6ab8e9774d6fcff373d210727"
+ },
+ "src": "17848:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4893,
+ "nodeType": "ExpressionStatement",
+ "src": "17848:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4898,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4894,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17913:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4896,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313134",
+ "id": 4895,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17926:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_114_by_1",
+ "typeString": "int_const 114"
+ },
+ "value": "114"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17913:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783263353634633430343666363465646261363838336361303662626334353335",
+ "id": 4897,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17933:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_58934115900064290859232836743818134837_by_1",
+ "typeString": "int_const 5893...(30 digits omitted)...4837"
+ },
+ "value": "0x2c564c4046f64edba6883ca06bbc4535"
+ },
+ "src": "17913:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4899,
+ "nodeType": "ExpressionStatement",
+ "src": "17913:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4904,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4900,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "17978:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4902,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313135",
+ "id": 4901,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17991:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_115_by_1",
+ "typeString": "int_const 115"
+ },
+ "value": "115"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "17978:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783263323937306334333166393532363431653035636234393365323365656433",
+ "id": 4903,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17998:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_58701203159797865214654223853927263955_by_1",
+ "typeString": "int_const 5870...(30 digits omitted)...3955"
+ },
+ "value": "0x2c2970c431f952641e05cb493e23eed3"
+ },
+ "src": "17978:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4905,
+ "nodeType": "ExpressionStatement",
+ "src": "17978:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4910,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4906,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18043:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4908,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313136",
+ "id": 4907,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18056:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_116_by_1",
+ "typeString": "int_const 116"
+ },
+ "value": "116"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18043:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783262666430353630636439656231343536336263376330373332383536633138",
+ "id": 4909,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18063:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_58470564005548587984364862866899430424_by_1",
+ "typeString": "int_const 5847...(30 digits omitted)...0424"
+ },
+ "value": "0x2bfd0560cd9eb14563bc7c0732856c18"
+ },
+ "src": "18043:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4911,
+ "nodeType": "ExpressionStatement",
+ "src": "18043:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4916,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4912,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18108:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4914,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313137",
+ "id": 4913,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18121:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_117_by_1",
+ "typeString": "int_const 117"
+ },
+ "value": "117"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18108:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783262643130383465643033333266376666343135306639643065663431613263",
+ "id": 4915,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18128:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_58242162365693428406397594903403305516_by_1",
+ "typeString": "int_const 5824...(30 digits omitted)...5516"
+ },
+ "value": "0x2bd1084ed0332f7ff4150f9d0ef41a2c"
+ },
+ "src": "18108:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4917,
+ "nodeType": "ExpressionStatement",
+ "src": "18108:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4922,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4918,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18173:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4920,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313138",
+ "id": 4919,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18186:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_118_by_1",
+ "typeString": "int_const 118"
+ },
+ "value": "118"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18173:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783262613537376430666131363238623736643034306231326138323439326662",
+ "id": 4921,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18193:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_58015962964008307710970589788915405563_by_1",
+ "typeString": "int_const 5801...(30 digits omitted)...5563"
+ },
+ "value": "0x2ba577d0fa1628b76d040b12a82492fb"
+ },
+ "src": "18173:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4923,
+ "nodeType": "ExpressionStatement",
+ "src": "18173:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4928,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4924,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18238:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4926,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313139",
+ "id": 4925,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18251:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_119_by_1",
+ "typeString": "int_const 119"
+ },
+ "value": "119"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18238:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783262376135323333636432313538316538353565383964633266316538613932",
+ "id": 4927,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18258:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_57791931297201156866686511914608921234_by_1",
+ "typeString": "int_const 5779...(30 digits omitted)...1234"
+ },
+ "value": "0x2b7a5233cd21581e855e89dc2f1e8a92"
+ },
+ "src": "18238:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4929,
+ "nodeType": "ExpressionStatement",
+ "src": "18238:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4934,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4930,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18303:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4932,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313230",
+ "id": 4931,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18316:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_120_by_1",
+ "typeString": "int_const 120"
+ },
+ "value": "120"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18303:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783262346639356364343639303464303564373262646364653333376439636337",
+ "id": 4933,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18323:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_57570033613218293176076279351194000583_by_1",
+ "typeString": "int_const 5757...(30 digits omitted)...0583"
+ },
+ "value": "0x2b4f95cd46904d05d72bdcde337d9cc7"
+ },
+ "src": "18303:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4935,
+ "nodeType": "ExpressionStatement",
+ "src": "18303:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4940,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4936,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18368:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4938,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313231",
+ "id": 4937,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18381:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_121_by_1",
+ "typeString": "int_const 121"
+ },
+ "value": "121"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18368:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783262323534306663396234643961626261336661636136363931393134363735",
+ "id": 4939,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18388:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_57350236890292752974853833075473860213_by_1",
+ "typeString": "int_const 5735...(30 digits omitted)...0213"
+ },
+ "value": "0x2b2540fc9b4d9abba3faca6691914675"
+ },
+ "src": "18368:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4941,
+ "nodeType": "ExpressionStatement",
+ "src": "18368:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4946,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4942,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18433:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4944,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313232",
+ "id": 4943,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18446:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_122_by_1",
+ "typeString": "int_const 122"
+ },
+ "value": "122"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18433:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783261666235323239663638643038333064386265386164623061306462373066",
+ "id": 4945,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18453:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_57132508816704680555143857466604631823_by_1",
+ "typeString": "int_const 5713...(30 digits omitted)...1823"
+ },
+ "value": "0x2afb5229f68d0830d8be8adb0a0db70f"
+ },
+ "src": "18433:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4947,
+ "nodeType": "ExpressionStatement",
+ "src": "18433:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4952,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4948,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18498:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4950,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313233",
+ "id": 4949,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18511:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_123_by_1",
+ "typeString": "int_const 123"
+ },
+ "value": "123"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18498:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783261643163376336336139623239346335626337336133626133616237613262",
+ "id": 4951,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18518:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_56916817771225259240345926660426267179_by_1",
+ "typeString": "int_const 5691...(30 digits omitted)...7179"
+ },
+ "value": "0x2ad1c7c63a9b294c5bc73a3ba3ab7a2b"
+ },
+ "src": "18498:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4953,
+ "nodeType": "ExpressionStatement",
+ "src": "18498:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4958,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4954,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18563:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4956,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313234",
+ "id": 4955,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18576:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_124_by_1",
+ "typeString": "int_const 124"
+ },
+ "value": "124"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18563:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783261613861303461633363626531656531633963383633363134363564626238",
+ "id": 4957,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18583:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_56703132804216983807771297030642981816_by_1",
+ "typeString": "int_const 5670...(30 digits omitted)...1816"
+ },
+ "value": "0x2aa8a04ac3cbe1ee1c9c86361465dbb8"
+ },
+ "src": "18563:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4959,
+ "nodeType": "ExpressionStatement",
+ "src": "18563:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4964,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4960,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18628:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4962,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313235",
+ "id": 4961,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18641:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_125_by_1",
+ "typeString": "int_const 125"
+ },
+ "value": "125"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18628:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783261376664613339326437323561343461326338616562396162333534333064",
+ "id": 4963,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18648:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_56491423619364318412491401339172373261_by_1",
+ "typeString": "int_const 5649...(30 digits omitted)...3261"
+ },
+ "value": "0x2a7fda392d725a44a2c8aeb9ab35430d"
+ },
+ "src": "18628:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4965,
+ "nodeType": "ExpressionStatement",
+ "src": "18628:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4970,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4966,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18693:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4968,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313236",
+ "id": 4967,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18706:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_126_by_1",
+ "typeString": "int_const 126"
+ },
+ "value": "126"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18693:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783261353737343162313863646536313837313737393262346661613231366462",
+ "id": 4969,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18713:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_56281660556009964768470705991401477851_by_1",
+ "typeString": "int_const 5628...(30 digits omitted)...7851"
+ },
+ "value": "0x2a57741b18cde618717792b4faa216db"
+ },
+ "src": "18693:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4971,
+ "nodeType": "ExpressionStatement",
+ "src": "18693:54:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 4976,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 4972,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "18758:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 4974,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "313237",
+ "id": 4973,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18771:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_127_by_1",
+ "typeString": "int_const 127"
+ },
+ "value": "127"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "18758:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783261326636633831663564383464643935306133353632366436643535303361",
+ "id": 4975,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18778:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_56073814572073085295245695095569469498_by_1",
+ "typeString": "int_const 5607...(30 digits omitted)...9498"
+ },
+ "value": "0x2a2f6c81f5d84dd950a35626d6d5503a"
+ },
+ "src": "18758:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 4977,
+ "nodeType": "ExpressionStatement",
+ "src": "18758:54:7"
+ }
+ ]
+ },
+ "documentation": null,
+ "id": 4979,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "initLambertArray",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 4208,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "10481:2:7"
+ },
+ "returnParameters": {
+ "id": 4209,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "10492:0:7"
+ },
+ "scope": 8977,
+ "src": "10456:8364:7",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 4989,
+ "nodeType": "Block",
+ "src": "18952:65:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "id": 4983,
+ "name": "initMaxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4203,
+ "src": "18963:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$",
+ "typeString": "function ()"
+ }
+ },
+ "id": 4984,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18963:17:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 4985,
+ "nodeType": "ExpressionStatement",
+ "src": "18963:17:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "id": 4986,
+ "name": "initLambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4979,
+ "src": "18991:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$",
+ "typeString": "function ()"
+ }
+ },
+ "id": 4987,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18991:18:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 4988,
+ "nodeType": "ExpressionStatement",
+ "src": "18991:18:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 4980,
+ "nodeType": "StructuredDocumentation",
+ "src": "18828:95:7",
+ "text": " @dev should be executed after construction (too large for the constructor)"
+ },
+ "functionSelector": "e1c7392a",
+ "id": 4990,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "init",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 4981,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "18942:2:7"
+ },
+ "returnParameters": {
+ "id": 4982,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "18952:0:7"
+ },
+ "scope": 8977,
+ "src": "18929:88:7",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "baseFunctions": [
+ 13092
+ ],
+ "body": {
+ "id": 5084,
+ "nodeType": "Block",
+ "src": "19968:795:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5008,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5006,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4993,
+ "src": "20014:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5007,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20024:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "20014:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f535550504c59",
+ "id": 5009,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20027:20:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ },
+ "value": "ERR_INVALID_SUPPLY"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ }
+ ],
+ "id": 5005,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "20006:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5010,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20006:42:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5011,
+ "nodeType": "ExpressionStatement",
+ "src": "20006:42:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5015,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5013,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4995,
+ "src": "20067:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5014,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20085:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "20067:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f42414c414e4345",
+ "id": 5016,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20088:29:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ },
+ "value": "ERR_INVALID_RESERVE_BALANCE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ }
+ ],
+ "id": 5012,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "20059:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5017,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20059:59:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5018,
+ "nodeType": "ExpressionStatement",
+ "src": "20059:59:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5026,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5022,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5020,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4997,
+ "src": "20137:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5021,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20154:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "20137:18:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5025,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5023,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4997,
+ "src": "20159:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5024,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "20177:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "20159:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "20137:50:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f574549474854",
+ "id": 5027,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20189:28:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_e4e4c57eb13b428a7fc031dc1f6f2c3e13b61f7d7b93994b2d17f8dc75658178",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_WEIGHT\""
+ },
+ "value": "ERR_INVALID_RESERVE_WEIGHT"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_e4e4c57eb13b428a7fc031dc1f6f2c3e13b61f7d7b93994b2d17f8dc75658178",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_WEIGHT\""
+ }
+ ],
+ "id": 5019,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "20129:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5028,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20129:89:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5029,
+ "nodeType": "ExpressionStatement",
+ "src": "20129:89:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5032,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5030,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4999,
+ "src": "20281:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5031,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20292:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "20281:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5035,
+ "nodeType": "IfStatement",
+ "src": "20277:39:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5033,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20315:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "functionReturnParameters": 5004,
+ "id": 5034,
+ "nodeType": "Return",
+ "src": "20308:8:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5038,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5036,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4997,
+ "src": "20379:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5037,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "20397:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "20379:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5046,
+ "nodeType": "IfStatement",
+ "src": "20375:92:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5044,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5041,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4999,
+ "src": "20441:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5039,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4993,
+ "src": "20429:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5040,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "20429:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5042,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20429:20:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5043,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4995,
+ "src": "20452:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "20429:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5004,
+ "id": 5045,
+ "nodeType": "Return",
+ "src": "20422:45:7"
+ }
+ },
+ {
+ "assignments": [
+ 5048
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5048,
+ "mutability": "mutable",
+ "name": "result",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5084,
+ "src": "20480:14:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5047,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "20480:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5049,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "20480:14:7"
+ },
+ {
+ "assignments": [
+ 5051
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5051,
+ "mutability": "mutable",
+ "name": "precision",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5084,
+ "src": "20505:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5050,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "20505:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5052,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "20505:15:7"
+ },
+ {
+ "assignments": [
+ 5054
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5054,
+ "mutability": "mutable",
+ "name": "baseN",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5084,
+ "src": "20531:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5053,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "20531:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5059,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5057,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4995,
+ "src": "20559:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5055,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4999,
+ "src": "20547:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5056,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "add",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22271,
+ "src": "20547:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5058,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20547:28:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "20531:44:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5069,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 5060,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5048,
+ "src": "20587:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5061,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5051,
+ "src": "20595:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5062,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "20586:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5064,
+ "name": "baseN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5054,
+ "src": "20614:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5065,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4995,
+ "src": "20621:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5066,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4997,
+ "src": "20638:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5067,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "20654:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ ],
+ "id": 5063,
+ "name": "power",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5820,
+ "src": "20608:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint32_$returns$_t_uint256_$_t_uint8_$",
+ "typeString": "function (uint256,uint256,uint32,uint32) view returns (uint256,uint8)"
+ }
+ },
+ "id": 5068,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20608:57:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "src": "20586:79:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5070,
+ "nodeType": "ExpressionStatement",
+ "src": "20586:79:7"
+ },
+ {
+ "assignments": [
+ 5072
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5072,
+ "mutability": "mutable",
+ "name": "temp",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5084,
+ "src": "20676:12:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5071,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "20676:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5079,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5078,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5075,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5048,
+ "src": "20703:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5073,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4993,
+ "src": "20691:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5074,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "20691:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5076,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20691:19:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5077,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5051,
+ "src": "20714:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "20691:32:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "20676:47:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5082,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5080,
+ "name": "temp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5072,
+ "src": "20741:4:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5081,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4993,
+ "src": "20748:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "20741:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5004,
+ "id": 5083,
+ "nodeType": "Return",
+ "src": "20734:21:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 4991,
+ "nodeType": "StructuredDocumentation",
+ "src": "19025:641:7",
+ "text": " @dev given a token supply, reserve balance, weight and a deposit amount (in the reserve token),\n calculates the target amount for a given conversion (in the main token)\n Formula:\n return = _supply * ((1 + _amount / _reserveBalance) ^ (_reserveWeight / 1000000) - 1)\n @param _supply smart token supply\n @param _reserveBalance reserve balance\n @param _reserveWeight reserve weight, represented in ppm (1-1000000)\n @param _amount amount of reserve tokens to get the target amount for\n @return smart token amount"
+ },
+ "functionSelector": "f3250fe2",
+ "id": 5085,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "purchaseTargetAmount",
+ "nodeType": "FunctionDefinition",
+ "overrides": {
+ "id": 5001,
+ "nodeType": "OverrideSpecifier",
+ "overrides": [],
+ "src": "19936:8:7"
+ },
+ "parameters": {
+ "id": 5000,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 4993,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5085,
+ "src": "19702:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 4992,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "19702:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 4995,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5085,
+ "src": "19754:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 4994,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "19754:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 4997,
+ "mutability": "mutable",
+ "name": "_reserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5085,
+ "src": "19814:21:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 4996,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "19814:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 4999,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5085,
+ "src": "19872:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 4998,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "19872:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "19701:187:7"
+ },
+ "returnParameters": {
+ "id": 5004,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5003,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5085,
+ "src": "19954:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5002,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "19954:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "19953:9:7"
+ },
+ "scope": 8977,
+ "src": "19672:1091:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "baseFunctions": [
+ 13105
+ ],
+ "body": {
+ "id": 5198,
+ "nodeType": "Block",
+ "src": "21691:1021:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5103,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5101,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5088,
+ "src": "21737:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5102,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "21747:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "21737:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f535550504c59",
+ "id": 5104,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "21750:20:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ },
+ "value": "ERR_INVALID_SUPPLY"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ }
+ ],
+ "id": 5100,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "21729:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5105,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21729:42:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5106,
+ "nodeType": "ExpressionStatement",
+ "src": "21729:42:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5110,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5108,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5090,
+ "src": "21790:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5109,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "21808:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "21790:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f42414c414e4345",
+ "id": 5111,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "21811:29:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ },
+ "value": "ERR_INVALID_RESERVE_BALANCE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ }
+ ],
+ "id": 5107,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "21782:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5112,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21782:59:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5113,
+ "nodeType": "ExpressionStatement",
+ "src": "21782:59:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5121,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5117,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5115,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5092,
+ "src": "21860:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5116,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "21877:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "21860:18:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5120,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5118,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5092,
+ "src": "21882:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5119,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "21900:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "21882:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "21860:50:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f574549474854",
+ "id": 5122,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "21912:28:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_e4e4c57eb13b428a7fc031dc1f6f2c3e13b61f7d7b93994b2d17f8dc75658178",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_WEIGHT\""
+ },
+ "value": "ERR_INVALID_RESERVE_WEIGHT"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_e4e4c57eb13b428a7fc031dc1f6f2c3e13b61f7d7b93994b2d17f8dc75658178",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_WEIGHT\""
+ }
+ ],
+ "id": 5114,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "21852:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5123,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21852:89:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5124,
+ "nodeType": "ExpressionStatement",
+ "src": "21852:89:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5128,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5126,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5094,
+ "src": "21960:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5127,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5088,
+ "src": "21971:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "21960:18:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f414d4f554e54",
+ "id": 5129,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "21980:20:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_c44007bfe4e704be0ed1393660a827b4f88825f4b6fe1bc10cd38fc3fcb7d839",
+ "typeString": "literal_string \"ERR_INVALID_AMOUNT\""
+ },
+ "value": "ERR_INVALID_AMOUNT"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_c44007bfe4e704be0ed1393660a827b4f88825f4b6fe1bc10cd38fc3fcb7d839",
+ "typeString": "literal_string \"ERR_INVALID_AMOUNT\""
+ }
+ ],
+ "id": 5125,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "21952:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5130,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21952:49:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5131,
+ "nodeType": "ExpressionStatement",
+ "src": "21952:49:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5134,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5132,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5094,
+ "src": "22061:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5133,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "22072:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "22061:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5137,
+ "nodeType": "IfStatement",
+ "src": "22057:39:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5135,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "22095:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "functionReturnParameters": 5099,
+ "id": 5136,
+ "nodeType": "Return",
+ "src": "22088:8:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5140,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5138,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5094,
+ "src": "22168:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5139,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5088,
+ "src": "22179:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "22168:18:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5143,
+ "nodeType": "IfStatement",
+ "src": "22164:59:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5141,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5090,
+ "src": "22208:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5099,
+ "id": 5142,
+ "nodeType": "Return",
+ "src": "22201:22:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5146,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5144,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5092,
+ "src": "22286:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5145,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "22304:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "22286:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5154,
+ "nodeType": "IfStatement",
+ "src": "22282:92:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5152,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5149,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5094,
+ "src": "22356:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5147,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5090,
+ "src": "22336:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5148,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "22336:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5150,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "22336:28:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5151,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5088,
+ "src": "22367:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "22336:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5099,
+ "id": 5153,
+ "nodeType": "Return",
+ "src": "22329:45:7"
+ }
+ },
+ {
+ "assignments": [
+ 5156
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5156,
+ "mutability": "mutable",
+ "name": "result",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5198,
+ "src": "22387:14:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5155,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "22387:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5157,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "22387:14:7"
+ },
+ {
+ "assignments": [
+ 5159
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5159,
+ "mutability": "mutable",
+ "name": "precision",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5198,
+ "src": "22412:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5158,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "22412:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5160,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "22412:15:7"
+ },
+ {
+ "assignments": [
+ 5162
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5162,
+ "mutability": "mutable",
+ "name": "baseD",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5198,
+ "src": "22438:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5161,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "22438:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5166,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5165,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5163,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5088,
+ "src": "22454:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5164,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5094,
+ "src": "22464:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "22454:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "22438:33:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5176,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 5167,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5156,
+ "src": "22483:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5168,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5159,
+ "src": "22491:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5169,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "22482:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5171,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5088,
+ "src": "22510:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5172,
+ "name": "baseD",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5162,
+ "src": "22519:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5173,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "22526:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5174,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5092,
+ "src": "22538:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ ],
+ "id": 5170,
+ "name": "power",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5820,
+ "src": "22504:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint32_$returns$_t_uint256_$_t_uint8_$",
+ "typeString": "function (uint256,uint256,uint32,uint32) view returns (uint256,uint8)"
+ }
+ },
+ "id": 5175,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "22504:49:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "src": "22482:71:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5177,
+ "nodeType": "ExpressionStatement",
+ "src": "22482:71:7"
+ },
+ {
+ "assignments": [
+ 5179
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5179,
+ "mutability": "mutable",
+ "name": "temp1",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5198,
+ "src": "22564:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5178,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "22564:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5184,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5182,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5156,
+ "src": "22600:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5180,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5090,
+ "src": "22580:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5181,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "22580:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5183,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "22580:27:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "22564:43:7"
+ },
+ {
+ "assignments": [
+ 5186
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5186,
+ "mutability": "mutable",
+ "name": "temp2",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5198,
+ "src": "22618:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5185,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "22618:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5190,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5189,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5187,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5090,
+ "src": "22634:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5188,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5159,
+ "src": "22653:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "22634:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "22618:44:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5196,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5193,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5191,
+ "name": "temp1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5179,
+ "src": "22681:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5192,
+ "name": "temp2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5186,
+ "src": "22689:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "22681:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 5194,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "22680:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5195,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5156,
+ "src": "22698:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "22680:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5099,
+ "id": 5197,
+ "nodeType": "Return",
+ "src": "22673:31:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5086,
+ "nodeType": "StructuredDocumentation",
+ "src": "20771:638:7",
+ "text": " @dev given a token supply, reserve balance, weight and a sell amount (in the main token),\n calculates the target amount for a given conversion (in the reserve token)\n Formula:\n return = _reserveBalance * (1 - (1 - _amount / _supply) ^ (1000000 / _reserveWeight))\n @param _supply smart token supply\n @param _reserveBalance reserve balance\n @param _reserveWeight reserve weight, represented in ppm (1-1000000)\n @param _amount amount of smart tokens to get the target amount for\n @return reserve token amount"
+ },
+ "functionSelector": "76cf0b56",
+ "id": 5199,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "saleTargetAmount",
+ "nodeType": "FunctionDefinition",
+ "overrides": {
+ "id": 5096,
+ "nodeType": "OverrideSpecifier",
+ "overrides": [],
+ "src": "21659:8:7"
+ },
+ "parameters": {
+ "id": 5095,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5088,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5199,
+ "src": "21441:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5087,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "21441:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5090,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5199,
+ "src": "21489:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5089,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "21489:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5092,
+ "mutability": "mutable",
+ "name": "_reserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5199,
+ "src": "21545:21:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5091,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "21545:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5094,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5199,
+ "src": "21599:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5093,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "21599:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "21440:175:7"
+ },
+ "returnParameters": {
+ "id": 5099,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5098,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5199,
+ "src": "21677:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5097,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "21677:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "21676:9:7"
+ },
+ "scope": 8977,
+ "src": "21415:1297:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "baseFunctions": [
+ 13120
+ ],
+ "body": {
+ "id": 5304,
+ "nodeType": "Block",
+ "src": "23978:921:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5223,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5219,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5217,
+ "name": "_sourceReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5202,
+ "src": "24024:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5218,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24048:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "24024:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5222,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5220,
+ "name": "_targetReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5206,
+ "src": "24053:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5221,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24077:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "24053:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "24024:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f42414c414e4345",
+ "id": 5224,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24080:29:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ },
+ "value": "ERR_INVALID_RESERVE_BALANCE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ }
+ ],
+ "id": 5216,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "24016:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5225,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24016:94:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5226,
+ "nodeType": "ExpressionStatement",
+ "src": "24016:94:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5242,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5238,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5234,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5230,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5228,
+ "name": "_sourceReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5204,
+ "src": "24129:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5229,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24152:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "24129:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5233,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5231,
+ "name": "_sourceReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5204,
+ "src": "24157:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5232,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "24181:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "24157:34:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "24129:62:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5237,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5235,
+ "name": "_targetReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5208,
+ "src": "24212:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5236,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24235:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "24212:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "24129:107:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5241,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5239,
+ "name": "_targetReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5208,
+ "src": "24240:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5240,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "24264:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "24240:34:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "24129:145:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f574549474854",
+ "id": 5243,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24276:28:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_e4e4c57eb13b428a7fc031dc1f6f2c3e13b61f7d7b93994b2d17f8dc75658178",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_WEIGHT\""
+ },
+ "value": "ERR_INVALID_RESERVE_WEIGHT"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_e4e4c57eb13b428a7fc031dc1f6f2c3e13b61f7d7b93994b2d17f8dc75658178",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_WEIGHT\""
+ }
+ ],
+ "id": 5227,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "24121:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5244,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24121:184:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5245,
+ "nodeType": "ExpressionStatement",
+ "src": "24121:184:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5248,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5246,
+ "name": "_sourceReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5204,
+ "src": "24365:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5247,
+ "name": "_targetReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5208,
+ "src": "24389:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "24365:44:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5259,
+ "nodeType": "IfStatement",
+ "src": "24361:141:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5257,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5251,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5210,
+ "src": "24457:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5249,
+ "name": "_targetReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5206,
+ "src": "24431:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5250,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "24431:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5252,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24431:34:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5255,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5210,
+ "src": "24494:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5253,
+ "name": "_sourceReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5202,
+ "src": "24468:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5254,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "add",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22271,
+ "src": "24468:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5256,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24468:34:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "24431:71:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5215,
+ "id": 5258,
+ "nodeType": "Return",
+ "src": "24424:78:7"
+ }
+ },
+ {
+ "assignments": [
+ 5261
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5261,
+ "mutability": "mutable",
+ "name": "result",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5304,
+ "src": "24515:14:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5260,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "24515:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5262,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24515:14:7"
+ },
+ {
+ "assignments": [
+ 5264
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5264,
+ "mutability": "mutable",
+ "name": "precision",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5304,
+ "src": "24540:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5263,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "24540:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5265,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24540:15:7"
+ },
+ {
+ "assignments": [
+ 5267
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5267,
+ "mutability": "mutable",
+ "name": "baseN",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5304,
+ "src": "24566:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5266,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "24566:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5272,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5270,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5210,
+ "src": "24608:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5268,
+ "name": "_sourceReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5202,
+ "src": "24582:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5269,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "add",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22271,
+ "src": "24582:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5271,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24582:34:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24566:50:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5282,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 5273,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5261,
+ "src": "24628:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5274,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5264,
+ "src": "24636:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5275,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "24627:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5277,
+ "name": "baseN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5267,
+ "src": "24655:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5278,
+ "name": "_sourceReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5202,
+ "src": "24662:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5279,
+ "name": "_sourceReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5204,
+ "src": "24685:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5280,
+ "name": "_targetReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5208,
+ "src": "24707:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ ],
+ "id": 5276,
+ "name": "power",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5820,
+ "src": "24649:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint32_$returns$_t_uint256_$_t_uint8_$",
+ "typeString": "function (uint256,uint256,uint32,uint32) view returns (uint256,uint8)"
+ }
+ },
+ "id": 5281,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24649:79:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "src": "24627:101:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5283,
+ "nodeType": "ExpressionStatement",
+ "src": "24627:101:7"
+ },
+ {
+ "assignments": [
+ 5285
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5285,
+ "mutability": "mutable",
+ "name": "temp1",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5304,
+ "src": "24739:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5284,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "24739:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5290,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5288,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5261,
+ "src": "24781:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5286,
+ "name": "_targetReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5206,
+ "src": "24755:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5287,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "24755:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5289,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24755:33:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24739:49:7"
+ },
+ {
+ "assignments": [
+ 5292
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5292,
+ "mutability": "mutable",
+ "name": "temp2",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5304,
+ "src": "24799:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5291,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "24799:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5296,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5295,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5293,
+ "name": "_targetReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5206,
+ "src": "24815:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5294,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5264,
+ "src": "24840:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "24815:34:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24799:50:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5302,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5299,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5297,
+ "name": "temp1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5285,
+ "src": "24868:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5298,
+ "name": "temp2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5292,
+ "src": "24876:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "24868:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 5300,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "24867:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5301,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5261,
+ "src": "24885:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "24867:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5215,
+ "id": 5303,
+ "nodeType": "Return",
+ "src": "24860:31:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5200,
+ "nodeType": "StructuredDocumentation",
+ "src": "22720:842:7",
+ "text": " @dev given two reserve balances/weights and a sell amount (in the first reserve token),\n calculates the target amount for a conversion from the source reserve token to the target reserve token\n Formula:\n return = _targetReserveBalance * (1 - (_sourceReserveBalance / (_sourceReserveBalance + _amount)) ^ (_sourceReserveWeight / _targetReserveWeight))\n @param _sourceReserveBalance source reserve balance\n @param _sourceReserveWeight source reserve weight, represented in ppm (1-1000000)\n @param _targetReserveBalance target reserve balance\n @param _targetReserveWeight target reserve weight, represented in ppm (1-1000000)\n @param _amount source reserve amount\n @return target reserve amount"
+ },
+ "functionSelector": "94491fab",
+ "id": 5305,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "crossReserveTargetAmount",
+ "nodeType": "FunctionDefinition",
+ "overrides": {
+ "id": 5212,
+ "nodeType": "OverrideSpecifier",
+ "overrides": [],
+ "src": "23946:8:7"
+ },
+ "parameters": {
+ "id": 5211,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5202,
+ "mutability": "mutable",
+ "name": "_sourceReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5305,
+ "src": "23602:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5201,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "23602:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5204,
+ "mutability": "mutable",
+ "name": "_sourceReserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5305,
+ "src": "23672:27:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5203,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "23672:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5206,
+ "mutability": "mutable",
+ "name": "_targetReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5305,
+ "src": "23740:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5205,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "23740:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5208,
+ "mutability": "mutable",
+ "name": "_targetReserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5305,
+ "src": "23810:27:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5207,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "23810:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5210,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5305,
+ "src": "23878:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5209,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "23878:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "23601:293:7"
+ },
+ "returnParameters": {
+ "id": 5215,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5214,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5305,
+ "src": "23964:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5213,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "23964:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "23963:9:7"
+ },
+ "scope": 8977,
+ "src": "23568:1331:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "baseFunctions": [
+ 13133
+ ],
+ "body": {
+ "id": 5412,
+ "nodeType": "Block",
+ "src": "25813:815:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5323,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5321,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5308,
+ "src": "25859:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5322,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "25869:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "25859:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f535550504c59",
+ "id": 5324,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "25872:20:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ },
+ "value": "ERR_INVALID_SUPPLY"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ }
+ ],
+ "id": 5320,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "25851:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5325,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "25851:42:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5326,
+ "nodeType": "ExpressionStatement",
+ "src": "25851:42:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5330,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5328,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5310,
+ "src": "25912:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5329,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "25930:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "25912:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f42414c414e4345",
+ "id": 5331,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "25933:29:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ },
+ "value": "ERR_INVALID_RESERVE_BALANCE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ }
+ ],
+ "id": 5327,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "25904:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5332,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "25904:59:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5333,
+ "nodeType": "ExpressionStatement",
+ "src": "25904:59:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5343,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5337,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5335,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5312,
+ "src": "25982:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5336,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "25998:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "25982:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5342,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5338,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5312,
+ "src": "26003:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5341,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5339,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "26020:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 5340,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26033:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "26020:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "26003:31:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "25982:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f524154494f",
+ "id": 5344,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26036:27:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_8a8172d57fd89f78d9ce572e7618cbce6e9962212a6741dcc1911f87bc706d73",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_RATIO\""
+ },
+ "value": "ERR_INVALID_RESERVE_RATIO"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_8a8172d57fd89f78d9ce572e7618cbce6e9962212a6741dcc1911f87bc706d73",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_RATIO\""
+ }
+ ],
+ "id": 5334,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "25974:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5345,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "25974:90:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5346,
+ "nodeType": "ExpressionStatement",
+ "src": "25974:90:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5349,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5347,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5314,
+ "src": "26119:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5348,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26130:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "26119:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5352,
+ "nodeType": "IfStatement",
+ "src": "26115:39:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5350,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26153:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "functionReturnParameters": 5319,
+ "id": 5351,
+ "nodeType": "Return",
+ "src": "26146:8:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5355,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5353,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5312,
+ "src": "26224:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5354,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "26241:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "26224:27:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5368,
+ "nodeType": "IfStatement",
+ "src": "26220:101:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5366,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5364,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5361,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5358,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5310,
+ "src": "26286:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5356,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5314,
+ "src": "26274:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5357,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "26274:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5359,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "26274:28:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5360,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26305:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "26274:32:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 5362,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "26273:34:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5363,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5308,
+ "src": "26310:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "26273:44:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5365,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26320:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "26273:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5319,
+ "id": 5367,
+ "nodeType": "Return",
+ "src": "26266:55:7"
+ }
+ },
+ {
+ "assignments": [
+ 5370
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5370,
+ "mutability": "mutable",
+ "name": "result",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5412,
+ "src": "26334:14:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5369,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "26334:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5371,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "26334:14:7"
+ },
+ {
+ "assignments": [
+ 5373
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5373,
+ "mutability": "mutable",
+ "name": "precision",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5412,
+ "src": "26359:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5372,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "26359:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5374,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "26359:15:7"
+ },
+ {
+ "assignments": [
+ 5376
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5376,
+ "mutability": "mutable",
+ "name": "baseN",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5412,
+ "src": "26385:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5375,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "26385:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5381,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5379,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5314,
+ "src": "26413:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5377,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5308,
+ "src": "26401:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5378,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "add",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22271,
+ "src": "26401:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5380,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "26401:20:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "26385:36:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5391,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 5382,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5370,
+ "src": "26433:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5383,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5373,
+ "src": "26441:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5384,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "26432:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5386,
+ "name": "baseN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5376,
+ "src": "26460:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5387,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5308,
+ "src": "26467:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5388,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "26476:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5389,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5312,
+ "src": "26488:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ ],
+ "id": 5385,
+ "name": "power",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5820,
+ "src": "26454:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint32_$returns$_t_uint256_$_t_uint8_$",
+ "typeString": "function (uint256,uint256,uint32,uint32) view returns (uint256,uint8)"
+ }
+ },
+ "id": 5390,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "26454:48:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "src": "26432:70:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5392,
+ "nodeType": "ExpressionStatement",
+ "src": "26432:70:7"
+ },
+ {
+ "assignments": [
+ 5394
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5394,
+ "mutability": "mutable",
+ "name": "temp",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5412,
+ "src": "26513:12:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5393,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "26513:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5407,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5406,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5403,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5400,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5397,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5370,
+ "src": "26550:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5395,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5310,
+ "src": "26530:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5396,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "26530:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5398,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "26530:27:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5399,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26560:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "26530:31:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 5401,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "26529:33:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5402,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5373,
+ "src": "26566:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "26529:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 5404,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "26528:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5405,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26579:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "26528:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "26513:67:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5410,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5408,
+ "name": "temp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5394,
+ "src": "26598:4:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5409,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5310,
+ "src": "26605:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "26598:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5319,
+ "id": 5411,
+ "nodeType": "Return",
+ "src": "26591:29:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5306,
+ "nodeType": "StructuredDocumentation",
+ "src": "24907:665:7",
+ "text": " @dev given a smart token supply, reserve balance, reserve ratio and an amount of requested smart tokens,\n calculates the amount of reserve tokens required for purchasing the given amount of smart tokens\n Formula:\n return = _reserveBalance * (((_supply + _amount) / _supply) ^ (MAX_WEIGHT / _reserveRatio) - 1)\n @param _supply smart token supply\n @param _reserveBalance reserve balance\n @param _reserveRatio reserve ratio, represented in ppm (2-2000000)\n @param _amount requested amount of smart tokens\n @return reserve token amount"
+ },
+ "functionSelector": "ebbb2158",
+ "id": 5413,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "fundCost",
+ "nodeType": "FunctionDefinition",
+ "overrides": {
+ "id": 5316,
+ "nodeType": "OverrideSpecifier",
+ "overrides": [],
+ "src": "25781:8:7"
+ },
+ "parameters": {
+ "id": 5315,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5308,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5413,
+ "src": "25596:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5307,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "25596:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5310,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5413,
+ "src": "25636:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5309,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "25636:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5312,
+ "mutability": "mutable",
+ "name": "_reserveRatio",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5413,
+ "src": "25684:20:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5311,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "25684:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5314,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5413,
+ "src": "25729:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5313,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "25729:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "25595:150:7"
+ },
+ "returnParameters": {
+ "id": 5319,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5318,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5413,
+ "src": "25799:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5317,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "25799:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "25798:9:7"
+ },
+ "scope": 8977,
+ "src": "25578:1050:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "baseFunctions": [
+ 13146
+ ],
+ "body": {
+ "id": 5509,
+ "nodeType": "Block",
+ "src": "27587:793:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5431,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5429,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5416,
+ "src": "27633:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5430,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27643:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "27633:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f535550504c59",
+ "id": 5432,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27646:20:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ },
+ "value": "ERR_INVALID_SUPPLY"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ }
+ ],
+ "id": 5428,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "27625:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5433,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "27625:42:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5434,
+ "nodeType": "ExpressionStatement",
+ "src": "27625:42:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5438,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5436,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5418,
+ "src": "27686:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5437,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27704:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "27686:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f42414c414e4345",
+ "id": 5439,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27707:29:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ },
+ "value": "ERR_INVALID_RESERVE_BALANCE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ }
+ ],
+ "id": 5435,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "27678:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5440,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "27678:59:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5441,
+ "nodeType": "ExpressionStatement",
+ "src": "27678:59:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5451,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5445,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5443,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5420,
+ "src": "27756:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5444,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27772:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "27756:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5450,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5446,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5420,
+ "src": "27777:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5449,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5447,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "27794:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 5448,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27807:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "27794:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "27777:31:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "27756:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f524154494f",
+ "id": 5452,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27810:27:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_8a8172d57fd89f78d9ce572e7618cbce6e9962212a6741dcc1911f87bc706d73",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_RATIO\""
+ },
+ "value": "ERR_INVALID_RESERVE_RATIO"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_8a8172d57fd89f78d9ce572e7618cbce6e9962212a6741dcc1911f87bc706d73",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_RATIO\""
+ }
+ ],
+ "id": 5442,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "27748:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5453,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "27748:90:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5454,
+ "nodeType": "ExpressionStatement",
+ "src": "27748:90:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5457,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5455,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5422,
+ "src": "27893:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5456,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27904:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "27893:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5460,
+ "nodeType": "IfStatement",
+ "src": "27889:39:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5458,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27927:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "functionReturnParameters": 5427,
+ "id": 5459,
+ "nodeType": "Return",
+ "src": "27920:8:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5463,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5461,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5420,
+ "src": "27998:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5462,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "28015:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "27998:27:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5471,
+ "nodeType": "IfStatement",
+ "src": "27994:91:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5469,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5466,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5416,
+ "src": "28059:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5464,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5422,
+ "src": "28047:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5465,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "28047:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5467,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28047:20:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5468,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5418,
+ "src": "28070:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "28047:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5427,
+ "id": 5470,
+ "nodeType": "Return",
+ "src": "28040:45:7"
+ }
+ },
+ {
+ "assignments": [
+ 5473
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5473,
+ "mutability": "mutable",
+ "name": "result",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5509,
+ "src": "28098:14:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5472,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "28098:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5474,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "28098:14:7"
+ },
+ {
+ "assignments": [
+ 5476
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5476,
+ "mutability": "mutable",
+ "name": "precision",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5509,
+ "src": "28123:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5475,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "28123:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5477,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "28123:15:7"
+ },
+ {
+ "assignments": [
+ 5479
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5479,
+ "mutability": "mutable",
+ "name": "baseN",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5509,
+ "src": "28149:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5478,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "28149:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5484,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5482,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5422,
+ "src": "28185:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5480,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5418,
+ "src": "28165:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5481,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "add",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22271,
+ "src": "28165:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5483,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28165:28:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "28149:44:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5494,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 5485,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5473,
+ "src": "28205:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5486,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5476,
+ "src": "28213:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5487,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "28204:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5489,
+ "name": "baseN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5479,
+ "src": "28232:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5490,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5418,
+ "src": "28239:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5491,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5420,
+ "src": "28256:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5492,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "28271:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ ],
+ "id": 5488,
+ "name": "power",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5820,
+ "src": "28226:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint32_$returns$_t_uint256_$_t_uint8_$",
+ "typeString": "function (uint256,uint256,uint32,uint32) view returns (uint256,uint8)"
+ }
+ },
+ "id": 5493,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28226:56:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "src": "28204:78:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5495,
+ "nodeType": "ExpressionStatement",
+ "src": "28204:78:7"
+ },
+ {
+ "assignments": [
+ 5497
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5497,
+ "mutability": "mutable",
+ "name": "temp",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5509,
+ "src": "28293:12:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5496,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "28293:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5504,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5503,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5500,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5473,
+ "src": "28320:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5498,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5416,
+ "src": "28308:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5499,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "28308:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5501,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28308:19:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5502,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5476,
+ "src": "28331:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "28308:32:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "28293:47:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5507,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5505,
+ "name": "temp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5497,
+ "src": "28358:4:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5506,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5416,
+ "src": "28365:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "28358:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5427,
+ "id": 5508,
+ "nodeType": "Return",
+ "src": "28351:21:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5414,
+ "nodeType": "StructuredDocumentation",
+ "src": "26636:670:7",
+ "text": " @dev given a smart token supply, reserve balance, reserve ratio and an amount of reserve tokens to fund with,\n calculates the amount of smart tokens received for purchasing with the given amount of reserve tokens\n Formula:\n return = _supply * ((_amount / _reserveBalance + 1) ^ (_reserveRatio / MAX_WEIGHT) - 1)\n @param _supply smart token supply\n @param _reserveBalance reserve balance\n @param _reserveRatio reserve ratio, represented in ppm (2-2000000)\n @param _amount amount of reserve tokens to fund with\n @return smart token amount"
+ },
+ "functionSelector": "2f55bdb5",
+ "id": 5510,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "fundSupplyAmount",
+ "nodeType": "FunctionDefinition",
+ "overrides": {
+ "id": 5424,
+ "nodeType": "OverrideSpecifier",
+ "overrides": [],
+ "src": "27555:8:7"
+ },
+ "parameters": {
+ "id": 5423,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5416,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5510,
+ "src": "27338:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5415,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "27338:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5418,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5510,
+ "src": "27386:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5417,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "27386:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5420,
+ "mutability": "mutable",
+ "name": "_reserveRatio",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5510,
+ "src": "27442:20:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5419,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "27442:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5422,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5510,
+ "src": "27495:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5421,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "27495:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "27337:174:7"
+ },
+ "returnParameters": {
+ "id": 5427,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5426,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5510,
+ "src": "27573:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5425,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "27573:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "27572:9:7"
+ },
+ "scope": 8977,
+ "src": "27312:1068:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "baseFunctions": [
+ 13159
+ ],
+ "body": {
+ "id": 5625,
+ "nodeType": "Block",
+ "src": "29367:1026:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5528,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5526,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5513,
+ "src": "29413:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5527,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29423:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "29413:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f535550504c59",
+ "id": 5529,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29426:20:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ },
+ "value": "ERR_INVALID_SUPPLY"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_663f10355ba071616cc91891330bbbd56c18b20e7bda020baff58fa08722ec60",
+ "typeString": "literal_string \"ERR_INVALID_SUPPLY\""
+ }
+ ],
+ "id": 5525,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "29405:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5530,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29405:42:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5531,
+ "nodeType": "ExpressionStatement",
+ "src": "29405:42:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5535,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5533,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5515,
+ "src": "29466:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5534,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29484:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "29466:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f42414c414e4345",
+ "id": 5536,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29487:29:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ },
+ "value": "ERR_INVALID_RESERVE_BALANCE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ }
+ ],
+ "id": 5532,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "29458:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5537,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29458:59:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5538,
+ "nodeType": "ExpressionStatement",
+ "src": "29458:59:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5548,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5542,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5540,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5517,
+ "src": "29536:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5541,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29552:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "29536:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5547,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5543,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5517,
+ "src": "29557:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5546,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5544,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "29574:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 5545,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29587:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "29574:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "29557:31:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "29536:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f524154494f",
+ "id": 5549,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29590:27:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_8a8172d57fd89f78d9ce572e7618cbce6e9962212a6741dcc1911f87bc706d73",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_RATIO\""
+ },
+ "value": "ERR_INVALID_RESERVE_RATIO"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_8a8172d57fd89f78d9ce572e7618cbce6e9962212a6741dcc1911f87bc706d73",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_RATIO\""
+ }
+ ],
+ "id": 5539,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "29528:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5550,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29528:90:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5551,
+ "nodeType": "ExpressionStatement",
+ "src": "29528:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5555,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5553,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5519,
+ "src": "29637:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5554,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5513,
+ "src": "29648:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "29637:18:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f414d4f554e54",
+ "id": 5556,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29657:20:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_c44007bfe4e704be0ed1393660a827b4f88825f4b6fe1bc10cd38fc3fcb7d839",
+ "typeString": "literal_string \"ERR_INVALID_AMOUNT\""
+ },
+ "value": "ERR_INVALID_AMOUNT"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_c44007bfe4e704be0ed1393660a827b4f88825f4b6fe1bc10cd38fc3fcb7d839",
+ "typeString": "literal_string \"ERR_INVALID_AMOUNT\""
+ }
+ ],
+ "id": 5552,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "29629:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5557,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29629:49:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5558,
+ "nodeType": "ExpressionStatement",
+ "src": "29629:49:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5561,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5559,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5519,
+ "src": "29733:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5560,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29744:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "29733:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5564,
+ "nodeType": "IfStatement",
+ "src": "29729:39:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5562,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29767:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "functionReturnParameters": 5524,
+ "id": 5563,
+ "nodeType": "Return",
+ "src": "29760:8:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5567,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5565,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5519,
+ "src": "29844:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5566,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5513,
+ "src": "29855:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "29844:18:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5570,
+ "nodeType": "IfStatement",
+ "src": "29840:59:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5568,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5515,
+ "src": "29884:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5524,
+ "id": 5569,
+ "nodeType": "Return",
+ "src": "29877:22:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "id": 5573,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5571,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5517,
+ "src": "29969:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5572,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "29986:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "29969:27:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5581,
+ "nodeType": "IfStatement",
+ "src": "29965:91:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5579,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5576,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5515,
+ "src": "30030:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5574,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5519,
+ "src": "30018:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5575,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "30018:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5577,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30018:28:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5578,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5513,
+ "src": "30049:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "30018:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5524,
+ "id": 5580,
+ "nodeType": "Return",
+ "src": "30011:45:7"
+ }
+ },
+ {
+ "assignments": [
+ 5583
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5583,
+ "mutability": "mutable",
+ "name": "result",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5625,
+ "src": "30069:14:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5582,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30069:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5584,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "30069:14:7"
+ },
+ {
+ "assignments": [
+ 5586
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5586,
+ "mutability": "mutable",
+ "name": "precision",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5625,
+ "src": "30094:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5585,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "30094:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5587,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "30094:15:7"
+ },
+ {
+ "assignments": [
+ 5589
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5589,
+ "mutability": "mutable",
+ "name": "baseD",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5625,
+ "src": "30120:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5588,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30120:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5593,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5592,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5590,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5513,
+ "src": "30136:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5591,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5519,
+ "src": "30146:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "30136:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "30120:33:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5603,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 5594,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5583,
+ "src": "30165:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5595,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5586,
+ "src": "30173:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5596,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "30164:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5598,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5513,
+ "src": "30192:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5599,
+ "name": "baseD",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5589,
+ "src": "30201:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5600,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "30208:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5601,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5517,
+ "src": "30220:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ ],
+ "id": 5597,
+ "name": "power",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5820,
+ "src": "30186:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint32_$returns$_t_uint256_$_t_uint8_$",
+ "typeString": "function (uint256,uint256,uint32,uint32) view returns (uint256,uint8)"
+ }
+ },
+ "id": 5602,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30186:48:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "src": "30164:70:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5604,
+ "nodeType": "ExpressionStatement",
+ "src": "30164:70:7"
+ },
+ {
+ "assignments": [
+ 5606
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5606,
+ "mutability": "mutable",
+ "name": "temp1",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5625,
+ "src": "30245:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5605,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30245:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5611,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5609,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5583,
+ "src": "30281:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5607,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5515,
+ "src": "30261:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5608,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "30261:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5610,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30261:27:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "30245:43:7"
+ },
+ {
+ "assignments": [
+ 5613
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5613,
+ "mutability": "mutable",
+ "name": "temp2",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5625,
+ "src": "30299:13:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5612,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30299:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5617,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5616,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5614,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5515,
+ "src": "30315:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5615,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5586,
+ "src": "30334:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "30315:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "30299:44:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5623,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5620,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5618,
+ "name": "temp1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5606,
+ "src": "30362:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5619,
+ "name": "temp2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5613,
+ "src": "30370:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "30362:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 5621,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "30361:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5622,
+ "name": "result",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5583,
+ "src": "30379:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "30361:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5524,
+ "id": 5624,
+ "nodeType": "Return",
+ "src": "30354:31:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5511,
+ "nodeType": "StructuredDocumentation",
+ "src": "28388:668:7",
+ "text": " @dev given a smart token supply, reserve balance, reserve ratio and an amount of smart tokens to liquidate,\n calculates the amount of reserve tokens received for selling the given amount of smart tokens\n Formula:\n return = _reserveBalance * (1 - ((_supply - _amount) / _supply) ^ (MAX_WEIGHT / _reserveRatio))\n @param _supply smart token supply\n @param _reserveBalance reserve balance\n @param _reserveRatio reserve ratio, represented in ppm (2-2000000)\n @param _amount amount of smart tokens to liquidate\n @return reserve token amount"
+ },
+ "functionSelector": "8074590a",
+ "id": 5626,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "liquidateReserveAmount",
+ "nodeType": "FunctionDefinition",
+ "overrides": {
+ "id": 5521,
+ "nodeType": "OverrideSpecifier",
+ "overrides": [],
+ "src": "29335:8:7"
+ },
+ "parameters": {
+ "id": 5520,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5513,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5626,
+ "src": "29094:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5512,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "29094:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5515,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5626,
+ "src": "29148:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5514,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "29148:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5517,
+ "mutability": "mutable",
+ "name": "_reserveRatio",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5626,
+ "src": "29210:20:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5516,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "29210:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5519,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5626,
+ "src": "29269:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5518,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "29269:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "29093:192:7"
+ },
+ "returnParameters": {
+ "id": 5524,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5523,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5626,
+ "src": "29353:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5522,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "29353:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "29352:9:7"
+ },
+ "scope": 8977,
+ "src": "29062:1331:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "baseFunctions": [
+ 13176
+ ],
+ "body": {
+ "id": 5729,
+ "nodeType": "Block",
+ "src": "33118:1031:7",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5647,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5645,
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5629,
+ "src": "33133:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5646,
+ "name": "_primaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5631,
+ "src": "33165:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "33133:54:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5670,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5666,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5662,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5660,
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5629,
+ "src": "33343:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5661,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33374:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "33343:32:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5665,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5663,
+ "name": "_primaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5631,
+ "src": "33379:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5664,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33404:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "33379:26:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "33343:62:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5669,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5667,
+ "name": "_secondaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5633,
+ "src": "33409:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5668,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33436:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "33409:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "33343:94:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f42414c414e4345",
+ "id": 5671,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33439:29:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ },
+ "value": "ERR_INVALID_RESERVE_BALANCE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ }
+ ],
+ "id": 5659,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "33335:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5672,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33335:134:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5673,
+ "nodeType": "ExpressionStatement",
+ "src": "33335:134:7"
+ },
+ "id": 5674,
+ "nodeType": "IfStatement",
+ "src": "33129:340:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5655,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5651,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5649,
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5629,
+ "src": "33210:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5650,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33241:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "33210:32:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "||",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5654,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5652,
+ "name": "_secondaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5633,
+ "src": "33246:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5653,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33273:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "33246:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "33210:64:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f42414c414e4345",
+ "id": 5656,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33276:29:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ },
+ "value": "ERR_INVALID_RESERVE_BALANCE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_50b448733a1d57cdd008d269297c4a2f50984605cb59e986bc2d98cee971e78d",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_BALANCE\""
+ }
+ ],
+ "id": 5648,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "33202:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5657,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33202:104:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5658,
+ "nodeType": "ExpressionStatement",
+ "src": "33202:104:7"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 5682,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5678,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5676,
+ "name": "_reserveRateNumerator",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5635,
+ "src": "33488:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5677,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33512:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "33488:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5681,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5679,
+ "name": "_reserveRateDenominator",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5637,
+ "src": "33517:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5680,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33543:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "33517:27:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "33488:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f524553455256455f52415445",
+ "id": 5683,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33546:26:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_ef2ffbf1bb88550d8f6c1cbc448ef8c9b658c0125c3eaac6dd7d95fb505ee813",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_RATE\""
+ },
+ "value": "ERR_INVALID_RESERVE_RATE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_ef2ffbf1bb88550d8f6c1cbc448ef8c9b658c0125c3eaac6dd7d95fb505ee813",
+ "typeString": "literal_string \"ERR_INVALID_RESERVE_RATE\""
+ }
+ ],
+ "id": 5675,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "33480:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 5684,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33480:93:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5685,
+ "nodeType": "ExpressionStatement",
+ "src": "33480:93:7"
+ },
+ {
+ "assignments": [
+ 5687
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5687,
+ "mutability": "mutable",
+ "name": "tq",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5729,
+ "src": "33586:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5686,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33586:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5692,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5690,
+ "name": "_reserveRateNumerator",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5635,
+ "src": "33632:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5688,
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5629,
+ "src": "33599:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5689,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "33599:32:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5691,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33599:55:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "33586:68:7"
+ },
+ {
+ "assignments": [
+ 5694
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5694,
+ "mutability": "mutable",
+ "name": "rp",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5729,
+ "src": "33665:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5693,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33665:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5699,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5697,
+ "name": "_reserveRateDenominator",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5637,
+ "src": "33707:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 5695,
+ "name": "_secondaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5633,
+ "src": "33678:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5696,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "33678:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5698,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33678:53:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "33665:66:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5702,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5700,
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5629,
+ "src": "33748:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5701,
+ "name": "_primaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5631,
+ "src": "33779:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "33748:53:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5711,
+ "nodeType": "IfStatement",
+ "src": "33744:169:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5704,
+ "name": "_primaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5631,
+ "src": "33846:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5705,
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5629,
+ "src": "33870:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5706,
+ "name": "tq",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5687,
+ "src": "33900:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5707,
+ "name": "rp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5694,
+ "src": "33904:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "74727565",
+ "id": 5708,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33908:4:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "true"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ ],
+ "id": 5703,
+ "name": "balancedWeightsByStake",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8547,
+ "src": "33823:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$returns$_t_uint32_$_t_uint32_$",
+ "typeString": "function (uint256,uint256,uint256,uint256,bool) view returns (uint32,uint32)"
+ }
+ },
+ "id": 5709,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33823:90:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint32_$_t_uint32_$",
+ "typeString": "tuple(uint32,uint32)"
+ }
+ },
+ "functionReturnParameters": 5644,
+ "id": 5710,
+ "nodeType": "Return",
+ "src": "33816:97:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5714,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5712,
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5629,
+ "src": "33930:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5713,
+ "name": "_primaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5631,
+ "src": "33961:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "33930:53:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5723,
+ "nodeType": "IfStatement",
+ "src": "33926:170:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5716,
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5629,
+ "src": "34028:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5717,
+ "name": "_primaryReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5631,
+ "src": "34058:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5718,
+ "name": "tq",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5687,
+ "src": "34082:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5719,
+ "name": "rp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5694,
+ "src": "34086:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "66616c7365",
+ "id": 5720,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "34090:5:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "false"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ ],
+ "id": 5715,
+ "name": "balancedWeightsByStake",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8547,
+ "src": "34005:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$returns$_t_uint32_$_t_uint32_$",
+ "typeString": "function (uint256,uint256,uint256,uint256,bool) view returns (uint32,uint32)"
+ }
+ },
+ "id": 5721,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "34005:91:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint32_$_t_uint32_$",
+ "typeString": "tuple(uint32,uint32)"
+ }
+ },
+ "functionReturnParameters": 5644,
+ "id": 5722,
+ "nodeType": "Return",
+ "src": "33998:98:7"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5725,
+ "name": "tq",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5687,
+ "src": "34134:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5726,
+ "name": "rp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5694,
+ "src": "34138:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 5724,
+ "name": "normalizedWeights",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8656,
+ "src": "34116:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint32_$_t_uint32_$",
+ "typeString": "function (uint256,uint256) pure returns (uint32,uint32)"
+ }
+ },
+ "id": 5727,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "34116:25:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint32_$_t_uint32_$",
+ "typeString": "tuple(uint32,uint32)"
+ }
+ },
+ "functionReturnParameters": 5644,
+ "id": 5728,
+ "nodeType": "Return",
+ "src": "34109:32:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5627,
+ "nodeType": "StructuredDocumentation",
+ "src": "30401:2317:7",
+ "text": " @dev The arbitrage incentive is to convert to the point where the on-chain price is equal to the off-chain price.\n We want this operation to also impact the primary reserve balance becoming equal to the primary reserve staked balance.\n In other words, we want the arbitrager to convert the difference between the reserve balance and the reserve staked balance.\n Formula input:\n - let t denote the primary reserve token staked balance\n - let s denote the primary reserve token balance\n - let r denote the secondary reserve token balance\n - let q denote the numerator of the rate between the tokens\n - let p denote the denominator of the rate between the tokens\n Where p primary tokens are equal to q secondary tokens\n Formula output:\n - compute x = W(t / r * q / p * log(s / t)) / log(s / t)\n - return x / (1 + x) as the weight of the primary reserve token\n - return 1 / (1 + x) as the weight of the secondary reserve token\n Where W is the Lambert W Function\n If the rate-provider provides the rates for a common unit, for example:\n - P = 2 ==> 2 primary reserve tokens = 1 ether\n - Q = 3 ==> 3 secondary reserve tokens = 1 ether\n Then you can simply use p = P and q = Q\n If the rate-provider provides the rates for a single unit, for example:\n - P = 2 ==> 1 primary reserve token = 2 ethers\n - Q = 3 ==> 1 secondary reserve token = 3 ethers\n Then you can simply use p = Q and q = P\n @param _primaryReserveStakedBalance the primary reserve token staked balance\n @param _primaryReserveBalance the primary reserve token balance\n @param _secondaryReserveBalance the secondary reserve token balance\n @param _reserveRateNumerator the numerator of the rate between the tokens\n @param _reserveRateDenominator the denominator of the rate between the tokens\n Note that `numerator / denominator` should represent the amount of secondary tokens equal to one primary token\n @return the weight of the primary reserve token and the weight of the secondary reserve token, both in ppm (0-1000000)"
+ },
+ "functionSelector": "a11aa1b4",
+ "id": 5730,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "balancedWeights",
+ "nodeType": "FunctionDefinition",
+ "overrides": {
+ "id": 5639,
+ "nodeType": "OverrideSpecifier",
+ "overrides": [],
+ "src": "33079:8:7"
+ },
+ "parameters": {
+ "id": 5638,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5629,
+ "mutability": "mutable",
+ "name": "_primaryReserveStakedBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5730,
+ "src": "32749:36:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5628,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32749:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5631,
+ "mutability": "mutable",
+ "name": "_primaryReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5730,
+ "src": "32817:30:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5630,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32817:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5633,
+ "mutability": "mutable",
+ "name": "_secondaryReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5730,
+ "src": "32879:32:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5632,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32879:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5635,
+ "mutability": "mutable",
+ "name": "_reserveRateNumerator",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5730,
+ "src": "32943:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5634,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32943:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5637,
+ "mutability": "mutable",
+ "name": "_reserveRateDenominator",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5730,
+ "src": "33004:31:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5636,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33004:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "32748:288:7"
+ },
+ "returnParameters": {
+ "id": 5644,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5641,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5730,
+ "src": "33097:6:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5640,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "33097:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5643,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5730,
+ "src": "33105:6:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5642,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "33105:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "33096:16:7"
+ },
+ "scope": 8977,
+ "src": "32724:1425:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 5819,
+ "nodeType": "Block",
+ "src": "35853:677:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5749,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5747,
+ "name": "_baseN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5733,
+ "src": "35872:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5748,
+ "name": "MAX_NUM",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3592,
+ "src": "35881:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "35872:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ ],
+ "id": 5746,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "35864:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
+ "typeString": "function (bool) pure"
+ }
+ },
+ "id": 5750,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "35864:25:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 5751,
+ "nodeType": "ExpressionStatement",
+ "src": "35864:25:7"
+ },
+ {
+ "assignments": [
+ 5753
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5753,
+ "mutability": "mutable",
+ "name": "baseLog",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5819,
+ "src": "35902:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5752,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "35902:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5754,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "35902:15:7"
+ },
+ {
+ "assignments": [
+ 5756
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5756,
+ "mutability": "mutable",
+ "name": "base",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5819,
+ "src": "35928:12:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5755,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "35928:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5762,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5761,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5759,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5757,
+ "name": "_baseN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5733,
+ "src": "35943:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5758,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "35952:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "35943:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5760,
+ "name": "_baseD",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5735,
+ "src": "35962:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "35943:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "35928:40:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5765,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5763,
+ "name": "base",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5756,
+ "src": "35983:4:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5764,
+ "name": "OPT_LOG_MAX_VAL",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3601,
+ "src": "35990:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "35983:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "id": 5779,
+ "nodeType": "Block",
+ "src": "36075:53:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5777,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5773,
+ "name": "baseLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5753,
+ "src": "36090:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5775,
+ "name": "base",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5756,
+ "src": "36111:4:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 5774,
+ "name": "generalLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5906,
+ "src": "36100:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5776,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "36100:16:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "36090:26:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5778,
+ "nodeType": "ExpressionStatement",
+ "src": "36090:26:7"
+ }
+ ]
+ },
+ "id": 5780,
+ "nodeType": "IfStatement",
+ "src": "35979:149:7",
+ "trueBody": {
+ "id": 5772,
+ "nodeType": "Block",
+ "src": "36007:53:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5770,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5766,
+ "name": "baseLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5753,
+ "src": "36022:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5768,
+ "name": "base",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5756,
+ "src": "36043:4:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 5767,
+ "name": "optimalLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6866,
+ "src": "36032:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5769,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "36032:16:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "36022:26:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5771,
+ "nodeType": "ExpressionStatement",
+ "src": "36022:26:7"
+ }
+ ]
+ }
+ },
+ {
+ "assignments": [
+ 5782
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5782,
+ "mutability": "mutable",
+ "name": "baseLogTimesExp",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5819,
+ "src": "36140:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5781,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "36140:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5788,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5787,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5785,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5783,
+ "name": "baseLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5753,
+ "src": "36166:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5784,
+ "name": "_expN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5737,
+ "src": "36176:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "36166:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5786,
+ "name": "_expD",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5739,
+ "src": "36184:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "36166:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "36140:49:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5791,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5789,
+ "name": "baseLogTimesExp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5782,
+ "src": "36204:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5790,
+ "name": "OPT_EXP_MAX_VAL",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3604,
+ "src": "36222:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "36204:33:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "id": 5817,
+ "nodeType": "Block",
+ "src": "36332:191:7",
+ "statements": [
+ {
+ "assignments": [
+ 5800
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5800,
+ "mutability": "mutable",
+ "name": "precision",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5817,
+ "src": "36347:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5799,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "36347:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5804,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5802,
+ "name": "baseLogTimesExp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5782,
+ "src": "36391:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 5801,
+ "name": "findPositionInMaxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6036,
+ "src": "36365:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint8_$",
+ "typeString": "function (uint256) view returns (uint8)"
+ }
+ },
+ "id": 5803,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "36365:42:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "36347:60:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5811,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5806,
+ "name": "baseLogTimesExp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5782,
+ "src": "36441:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "id": 5809,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5807,
+ "name": "MAX_PRECISION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3583,
+ "src": "36461:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5808,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5800,
+ "src": "36477:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "36461:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5810,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "36460:27:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "36441:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5812,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5800,
+ "src": "36489:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ ],
+ "id": 5805,
+ "name": "generalExp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6546,
+ "src": "36430:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint8_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint8) pure returns (uint256)"
+ }
+ },
+ "id": 5813,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "36430:69:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5814,
+ "name": "precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5800,
+ "src": "36501:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5815,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "36429:82:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "functionReturnParameters": 5745,
+ "id": 5816,
+ "nodeType": "Return",
+ "src": "36422:89:7"
+ }
+ ]
+ },
+ "id": 5818,
+ "nodeType": "IfStatement",
+ "src": "36200:323:7",
+ "trueBody": {
+ "id": 5798,
+ "nodeType": "Block",
+ "src": "36239:78:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 5793,
+ "name": "baseLogTimesExp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5782,
+ "src": "36273:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 5792,
+ "name": "optimalExp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7276,
+ "src": "36262:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 5794,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "36262:27:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 5795,
+ "name": "MAX_PRECISION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3583,
+ "src": "36291:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5796,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "36261:44:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint8_$",
+ "typeString": "tuple(uint256,uint8)"
+ }
+ },
+ "functionReturnParameters": 5745,
+ "id": 5797,
+ "nodeType": "Return",
+ "src": "36254:51:7"
+ }
+ ]
+ }
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5731,
+ "nodeType": "StructuredDocumentation",
+ "src": "34157:1576:7",
+ "text": " @dev General Description:\n Determine a value of precision.\n Calculate an integer approximation of (_baseN / _baseD) ^ (_expN / _expD) * 2 ^ precision.\n Return the result along with the precision used.\n Detailed Description:\n Instead of calculating \"base ^ exp\", we calculate \"e ^ (log(base) * exp)\".\n The value of \"log(base)\" is represented with an integer slightly smaller than \"log(base) * 2 ^ precision\".\n The larger \"precision\" is, the more accurately this value represents the real value.\n However, the larger \"precision\" is, the more bits are required in order to store this value.\n And the exponentiation function, which takes \"x\" and calculates \"e ^ x\", is limited to a maximum exponent (maximum value of \"x\").\n This maximum exponent depends on the \"precision\" used, and it is given by \"maxExpArray[precision] >> (MAX_PRECISION - precision)\".\n Hence we need to determine the highest precision which can be used for the given input, before calling the exponentiation function.\n This allows us to compute \"base ^ exp\" with maximum accuracy and without exceeding 256 bits in any of the intermediate computations.\n This functions assumes that \"_expN < 2 ^ 256 / log(MAX_NUM - 1)\", otherwise the multiplication should be replaced with a \"safeMul\".\n Since we rely on unsigned-integer arithmetic and \"base < 1\" ==> \"log(base) < 0\", this function does not support \"_baseN < _baseD\"."
+ },
+ "id": 5820,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "power",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 5740,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5733,
+ "mutability": "mutable",
+ "name": "_baseN",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5820,
+ "src": "35754:14:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5732,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "35754:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5735,
+ "mutability": "mutable",
+ "name": "_baseD",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5820,
+ "src": "35770:14:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5734,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "35770:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5737,
+ "mutability": "mutable",
+ "name": "_expN",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5820,
+ "src": "35786:12:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5736,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "35786:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5739,
+ "mutability": "mutable",
+ "name": "_expD",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5820,
+ "src": "35800:12:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 5738,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "35800:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "35753:60:7"
+ },
+ "returnParameters": {
+ "id": 5745,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5742,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5820,
+ "src": "35837:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5741,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "35837:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 5744,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5820,
+ "src": "35846:5:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5743,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "35846:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "35836:16:7"
+ },
+ "scope": 8977,
+ "src": "35739:791:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 5905,
+ "nodeType": "Block",
+ "src": "36770:760:7",
+ "statements": [
+ {
+ "assignments": [
+ 5829
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5829,
+ "mutability": "mutable",
+ "name": "res",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5905,
+ "src": "36781:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5828,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "36781:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5831,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5830,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "36795:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "36781:15:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5834,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5832,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "36905:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5833,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "36910:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "36905:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5854,
+ "nodeType": "IfStatement",
+ "src": "36901:156:7",
+ "trueBody": {
+ "id": 5853,
+ "nodeType": "Block",
+ "src": "36919:138:7",
+ "statements": [
+ {
+ "assignments": [
+ 5836
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5836,
+ "mutability": "mutable",
+ "name": "count",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5853,
+ "src": "36934:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5835,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "36934:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5842,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5840,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5838,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "36958:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5839,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "36962:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "36958:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 5837,
+ "name": "floorLog2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5969,
+ "src": "36948:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint8_$",
+ "typeString": "function (uint256) pure returns (uint8)"
+ }
+ },
+ "id": 5841,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "36948:22:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "36934:36:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5845,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5843,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "36985:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": ">>=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 5844,
+ "name": "count",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5836,
+ "src": "36991:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "36985:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5846,
+ "nodeType": "ExpressionStatement",
+ "src": "36985:11:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5851,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5847,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5829,
+ "src": "37024:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5850,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5848,
+ "name": "count",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5836,
+ "src": "37030:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5849,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "37038:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37030:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37024:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5852,
+ "nodeType": "ExpressionStatement",
+ "src": "37024:21:7"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5857,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5855,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "37165:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5856,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "37169:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37165:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5898,
+ "nodeType": "IfStatement",
+ "src": "37161:305:7",
+ "trueBody": {
+ "id": 5897,
+ "nodeType": "Block",
+ "src": "37178:288:7",
+ "statements": [
+ {
+ "body": {
+ "id": 5895,
+ "nodeType": "Block",
+ "src": "37235:220:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5875,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5868,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "37254:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5874,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5871,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5869,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "37259:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5870,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "37263:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37259:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 5872,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "37258:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5873,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "37268:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37258:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37254:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5876,
+ "nodeType": "ExpressionStatement",
+ "src": "37254:21:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5879,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5877,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "37315:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5878,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "37320:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37315:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5894,
+ "nodeType": "IfStatement",
+ "src": "37311:129:7",
+ "trueBody": {
+ "id": 5893,
+ "nodeType": "Block",
+ "src": "37329:111:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5882,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5880,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5823,
+ "src": "37352:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": ">>=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5881,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "37358:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "37352:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5883,
+ "nodeType": "ExpressionStatement",
+ "src": "37352:7:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5891,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5884,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5829,
+ "src": "37399:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5890,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5885,
+ "name": "ONE",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3574,
+ "src": "37406:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "id": 5888,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5886,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5859,
+ "src": "37414:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5887,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "37418:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "37414:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5889,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "37413:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "37406:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37399:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5892,
+ "nodeType": "ExpressionStatement",
+ "src": "37399:21:7"
+ }
+ ]
+ }
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "id": 5864,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5862,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5859,
+ "src": "37223:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5863,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "37227:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "37223:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 5896,
+ "initializationExpression": {
+ "assignments": [
+ 5859
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5859,
+ "mutability": "mutable",
+ "name": "i",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5896,
+ "src": "37198:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5858,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "37198:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5861,
+ "initialValue": {
+ "argumentTypes": null,
+ "id": 5860,
+ "name": "MAX_PRECISION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3583,
+ "src": "37208:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "37198:23:7"
+ },
+ "loopExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5866,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "--",
+ "prefix": true,
+ "src": "37230:3:7",
+ "subExpression": {
+ "argumentTypes": null,
+ "id": 5865,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5859,
+ "src": "37232:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "id": 5867,
+ "nodeType": "ExpressionStatement",
+ "src": "37230:3:7"
+ },
+ "nodeType": "ForStatement",
+ "src": "37193:262:7"
+ }
+ ]
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5903,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5901,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5899,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5829,
+ "src": "37485:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5900,
+ "name": "LN2_NUMERATOR",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3595,
+ "src": "37491:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37485:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5902,
+ "name": "LN2_DENOMINATOR",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3598,
+ "src": "37507:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "37485:37:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 5827,
+ "id": 5904,
+ "nodeType": "Return",
+ "src": "37478:44:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5821,
+ "nodeType": "StructuredDocumentation",
+ "src": "36538:163:7",
+ "text": " @dev computes log(x / FIXED_1) * FIXED_1.\n This functions assumes that \"x >= FIXED_1\", because the output would be negative otherwise."
+ },
+ "id": 5906,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "generalLog",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 5824,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5823,
+ "mutability": "mutable",
+ "name": "x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5906,
+ "src": "36727:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5822,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "36727:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "36726:11:7"
+ },
+ "returnParameters": {
+ "id": 5827,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5826,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5906,
+ "src": "36761:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5825,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "36761:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "36760:9:7"
+ },
+ "scope": 8977,
+ "src": "36707:823:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 5968,
+ "nodeType": "Block",
+ "src": "37719:481:7",
+ "statements": [
+ {
+ "assignments": [
+ 5915
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5915,
+ "mutability": "mutable",
+ "name": "res",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5968,
+ "src": "37730:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5914,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "37730:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5917,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5916,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "37742:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "37730:13:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5920,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5918,
+ "name": "_n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5909,
+ "src": "37760:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "323536",
+ "id": 5919,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "37765:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_256_by_1",
+ "typeString": "int_const 256"
+ },
+ "value": "256"
+ },
+ "src": "37760:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "id": 5964,
+ "nodeType": "Block",
+ "src": "37933:237:7",
+ "statements": [
+ {
+ "body": {
+ "id": 5962,
+ "nodeType": "Block",
+ "src": "38021:138:7",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5951,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5946,
+ "name": "_n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5909,
+ "src": "38044:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5949,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5947,
+ "name": "ONE",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3574,
+ "src": "38051:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5948,
+ "name": "s",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5936,
+ "src": "38058:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "38051:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 5950,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "38050:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "38044:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 5961,
+ "nodeType": "IfStatement",
+ "src": "38040:104:7",
+ "trueBody": {
+ "id": 5960,
+ "nodeType": "Block",
+ "src": "38062:82:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5954,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5952,
+ "name": "_n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5909,
+ "src": "38085:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": ">>=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 5953,
+ "name": "s",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5936,
+ "src": "38092:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "38085:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5955,
+ "nodeType": "ExpressionStatement",
+ "src": "38085:8:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5958,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5956,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5915,
+ "src": "38116:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "|=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 5957,
+ "name": "s",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5936,
+ "src": "38123:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "38116:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "id": 5959,
+ "nodeType": "ExpressionStatement",
+ "src": "38116:8:7"
+ }
+ ]
+ }
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "id": 5941,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5939,
+ "name": "s",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5936,
+ "src": "38005:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 5940,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "38009:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "38005:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 5963,
+ "initializationExpression": {
+ "assignments": [
+ 5936
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5936,
+ "mutability": "mutable",
+ "name": "s",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5963,
+ "src": "37990:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5935,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "37990:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5938,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "313238",
+ "id": 5937,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "38000:3:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_128_by_1",
+ "typeString": "int_const 128"
+ },
+ "value": "128"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "37990:13:7"
+ },
+ "loopExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5944,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5942,
+ "name": "s",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5936,
+ "src": "38012:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": ">>=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5943,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "38018:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "38012:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "id": 5945,
+ "nodeType": "ExpressionStatement",
+ "src": "38012:7:7"
+ },
+ "nodeType": "ForStatement",
+ "src": "37985:174:7"
+ }
+ ]
+ },
+ "id": 5965,
+ "nodeType": "IfStatement",
+ "src": "37756:414:7",
+ "trueBody": {
+ "id": 5934,
+ "nodeType": "Block",
+ "src": "37770:148:7",
+ "statements": [
+ {
+ "body": {
+ "id": 5932,
+ "nodeType": "Block",
+ "src": "37837:70:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5926,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5924,
+ "name": "_n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5909,
+ "src": "37856:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": ">>=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5925,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "37863:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "37856:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 5927,
+ "nodeType": "ExpressionStatement",
+ "src": "37856:8:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5930,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 5928,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5915,
+ "src": "37883:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5929,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "37890:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "37883:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "id": 5931,
+ "nodeType": "ExpressionStatement",
+ "src": "37883:8:7"
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 5923,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5921,
+ "name": "_n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5909,
+ "src": "37829:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5922,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "37834:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "37829:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 5933,
+ "nodeType": "WhileStatement",
+ "src": "37822:85:7"
+ }
+ ]
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 5966,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5915,
+ "src": "38189:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "functionReturnParameters": 5913,
+ "id": 5967,
+ "nodeType": "Return",
+ "src": "38182:10:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5907,
+ "nodeType": "StructuredDocumentation",
+ "src": "37538:114:7",
+ "text": " @dev computes the largest integer smaller than or equal to the binary logarithm of the input."
+ },
+ "id": 5969,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "floorLog2",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 5910,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5909,
+ "mutability": "mutable",
+ "name": "_n",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5969,
+ "src": "37677:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5908,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "37677:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "37676:12:7"
+ },
+ "returnParameters": {
+ "id": 5913,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5912,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 5969,
+ "src": "37712:5:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5911,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "37712:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "37711:7:7"
+ },
+ "scope": 8977,
+ "src": "37658:542:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 6035,
+ "nodeType": "Block",
+ "src": "38650:424:7",
+ "statements": [
+ {
+ "assignments": [
+ 5978
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5978,
+ "mutability": "mutable",
+ "name": "lo",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6035,
+ "src": "38661:8:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5977,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "38661:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5980,
+ "initialValue": {
+ "argumentTypes": null,
+ "id": 5979,
+ "name": "MIN_PRECISION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3580,
+ "src": "38672:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "38661:24:7"
+ },
+ {
+ "assignments": [
+ 5982
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5982,
+ "mutability": "mutable",
+ "name": "hi",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6035,
+ "src": "38696:8:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5981,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "38696:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5984,
+ "initialValue": {
+ "argumentTypes": null,
+ "id": 5983,
+ "name": "MAX_PRECISION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3583,
+ "src": "38707:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "38696:24:7"
+ },
+ {
+ "body": {
+ "id": 6013,
+ "nodeType": "Block",
+ "src": "38753:165:7",
+ "statements": [
+ {
+ "assignments": [
+ 5991
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 5991,
+ "mutability": "mutable",
+ "name": "mid",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6013,
+ "src": "38768:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5990,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "38768:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 5998,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "id": 5997,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "id": 5994,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5992,
+ "name": "lo",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5978,
+ "src": "38781:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5993,
+ "name": "hi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5982,
+ "src": "38786:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "38781:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 5995,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "38780:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 5996,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "38792:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "38780:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "38768:25:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6003,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 5999,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "38812:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 6001,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 6000,
+ "name": "mid",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5991,
+ "src": "38824:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "38812:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6002,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5972,
+ "src": "38832:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "38812:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6010,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6008,
+ "name": "hi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5982,
+ "src": "38898:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 6009,
+ "name": "mid",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5991,
+ "src": "38903:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "38898:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "id": 6011,
+ "nodeType": "ExpressionStatement",
+ "src": "38898:8:7"
+ },
+ "id": 6012,
+ "nodeType": "IfStatement",
+ "src": "38808:98:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6006,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6004,
+ "name": "lo",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5978,
+ "src": "38853:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 6005,
+ "name": "mid",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5991,
+ "src": "38858:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "38853:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "id": 6007,
+ "nodeType": "ExpressionStatement",
+ "src": "38853:8:7"
+ }
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "id": 5989,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "id": 5987,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 5985,
+ "name": "lo",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5978,
+ "src": "38740:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 5986,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "38745:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "38740:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 5988,
+ "name": "hi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5982,
+ "src": "38749:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "38740:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 6014,
+ "nodeType": "WhileStatement",
+ "src": "38733:185:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6019,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 6015,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "38934:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 6017,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 6016,
+ "name": "hi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5982,
+ "src": "38946:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "38934:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6018,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5972,
+ "src": "38953:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "38934:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6022,
+ "nodeType": "IfStatement",
+ "src": "38930:49:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6020,
+ "name": "hi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5982,
+ "src": "38977:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "functionReturnParameters": 5976,
+ "id": 6021,
+ "nodeType": "Return",
+ "src": "38970:9:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6027,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 6023,
+ "name": "maxExpArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3623,
+ "src": "38994:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 6025,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 6024,
+ "name": "lo",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5978,
+ "src": "39006:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "38994:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6026,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5972,
+ "src": "39013:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "38994:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6030,
+ "nodeType": "IfStatement",
+ "src": "38990:49:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6028,
+ "name": "lo",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5978,
+ "src": "39037:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "functionReturnParameters": 5976,
+ "id": 6029,
+ "nodeType": "Return",
+ "src": "39030:9:7"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "66616c7365",
+ "id": 6032,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "39060:5:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "false"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ ],
+ "id": 6031,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "39052:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
+ "typeString": "function (bool) pure"
+ }
+ },
+ "id": 6033,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "39052:14:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 6034,
+ "nodeType": "ExpressionStatement",
+ "src": "39052:14:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 5970,
+ "nodeType": "StructuredDocumentation",
+ "src": "38208:359:7",
+ "text": " @dev the global \"maxExpArray\" is sorted in descending order, and therefore the following statements are equivalent:\n - This function finds the position of [the smallest value in \"maxExpArray\" larger than or equal to \"x\"]\n - This function finds the highest position of [a value in \"maxExpArray\" larger than or equal to \"x\"]"
+ },
+ "id": 6036,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "findPositionInMaxExpArray",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 5973,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5972,
+ "mutability": "mutable",
+ "name": "_x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6036,
+ "src": "38608:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 5971,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "38608:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "38607:12:7"
+ },
+ "returnParameters": {
+ "id": 5976,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 5975,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6036,
+ "src": "38643:5:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 5974,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "38643:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "38642:7:7"
+ },
+ "scope": 8977,
+ "src": "38573:501:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 6545,
+ "nodeType": "Block",
+ "src": "39728:3782:7",
+ "statements": [
+ {
+ "assignments": [
+ 6047
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6047,
+ "mutability": "mutable",
+ "name": "xi",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6545,
+ "src": "39739:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6046,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "39739:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6049,
+ "initialValue": {
+ "argumentTypes": null,
+ "id": 6048,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "39752:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "39739:15:7"
+ },
+ {
+ "assignments": [
+ 6051
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6051,
+ "mutability": "mutable",
+ "name": "res",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6545,
+ "src": "39765:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6050,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "39765:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6053,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 6052,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "39779:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "39765:15:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6061,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6054,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "39793:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6060,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6057,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6055,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "39799:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6056,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "39804:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "39799:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6058,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "39798:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6059,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "39811:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "39798:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "39793:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6062,
+ "nodeType": "ExpressionStatement",
+ "src": "39793:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6067,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6063,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "39823:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6066,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6064,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "39830:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307833343432633465363037346138326631373937663732616330303030303030",
+ "id": 6065,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "39835:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4341658809405943247759097200640000000_by_1",
+ "typeString": "int_const 4341...(29 digits omitted)...0000"
+ },
+ "value": "0x3442c4e6074a82f1797f72ac0000000"
+ },
+ "src": "39830:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "39823:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6068,
+ "nodeType": "ExpressionStatement",
+ "src": "39823:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6076,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6069,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "39905:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6075,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6072,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6070,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "39911:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6071,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "39916:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "39911:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6073,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "39910:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6074,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "39923:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "39910:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "39905:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6077,
+ "nodeType": "ExpressionStatement",
+ "src": "39905:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6082,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6078,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "39935:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6081,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6079,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "39942:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307831313662393666373537633338306662323837666430653430303030303030",
+ "id": 6080,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "39947:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1447219603135314415919699066880000000_by_1",
+ "typeString": "int_const 1447...(29 digits omitted)...0000"
+ },
+ "value": "0x116b96f757c380fb287fd0e40000000"
+ },
+ "src": "39942:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "39935:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6083,
+ "nodeType": "ExpressionStatement",
+ "src": "39935:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6091,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6084,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40017:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6090,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6087,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6085,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40023:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6086,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40028:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40023:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6088,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40022:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6089,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40035:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40022:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40017:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6092,
+ "nodeType": "ExpressionStatement",
+ "src": "40017:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6097,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6093,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40047:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6096,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6094,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40054:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830343561653562646435663065303365636131666634333930303030303030",
+ "id": 6095,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40059:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_361804900783828603979924766720000000_by_1",
+ "typeString": "int_const 3618...(28 digits omitted)...0000"
+ },
+ "value": "0x045ae5bdd5f0e03eca1ff4390000000"
+ },
+ "src": "40054:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40047:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6098,
+ "nodeType": "ExpressionStatement",
+ "src": "40047:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6106,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6099,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40129:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6105,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6102,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6100,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40135:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6101,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40140:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40135:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6103,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40134:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6104,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40147:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40134:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40129:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6107,
+ "nodeType": "ExpressionStatement",
+ "src": "40129:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6112,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6108,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40159:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6111,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6109,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40166:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830306465666162663931333032636439356239666664613530303030303030",
+ "id": 6110,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40171:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_72360980156765720795984953344000000_by_1",
+ "typeString": "int_const 7236...(27 digits omitted)...0000"
+ },
+ "value": "0x00defabf91302cd95b9ffda50000000"
+ },
+ "src": "40166:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40159:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6113,
+ "nodeType": "ExpressionStatement",
+ "src": "40159:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6121,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6114,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40241:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6120,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6117,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6115,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40247:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6116,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40252:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40247:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6118,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40246:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6119,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40259:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40246:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40241:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6122,
+ "nodeType": "ExpressionStatement",
+ "src": "40241:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6127,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6123,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40271:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6126,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6124,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40278:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303235323963613938333262323234333965666666396238303030303030",
+ "id": 6125,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40283:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_12060163359460953465997492224000000_by_1",
+ "typeString": "int_const 1206...(27 digits omitted)...0000"
+ },
+ "value": "0x002529ca9832b22439efff9b8000000"
+ },
+ "src": "40278:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40271:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6128,
+ "nodeType": "ExpressionStatement",
+ "src": "40271:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6136,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6129,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40353:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6135,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6132,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6130,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40359:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6131,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40364:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40359:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6133,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40358:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6134,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40371:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40358:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40353:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6137,
+ "nodeType": "ExpressionStatement",
+ "src": "40353:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6142,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6138,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40383:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6141,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6139,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40390:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303035346631636631326264303465353136623664613838303030303030",
+ "id": 6140,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40395:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1722880479922993352285356032000000_by_1",
+ "typeString": "int_const 1722...(26 digits omitted)...0000"
+ },
+ "value": "0x00054f1cf12bd04e516b6da88000000"
+ },
+ "src": "40390:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40383:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6143,
+ "nodeType": "ExpressionStatement",
+ "src": "40383:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6151,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6144,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40465:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6150,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6147,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6145,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40471:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6146,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40476:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40471:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6148,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40470:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6149,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40483:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40470:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40465:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6152,
+ "nodeType": "ExpressionStatement",
+ "src": "40465:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6157,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6153,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40495:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6156,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6154,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40502:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030613965333965323537613039636132643664623531303030303030",
+ "id": 6155,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40507:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_215360059990374169035669504000000_by_1",
+ "typeString": "int_const 2153...(25 digits omitted)...0000"
+ },
+ "value": "0x0000a9e39e257a09ca2d6db51000000"
+ },
+ "src": "40502:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40495:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6158,
+ "nodeType": "ExpressionStatement",
+ "src": "40495:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6166,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6159,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40577:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6165,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6162,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6160,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40583:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6161,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40588:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40583:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6163,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40582:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6164,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40595:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40582:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40577:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6167,
+ "nodeType": "ExpressionStatement",
+ "src": "40577:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6172,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6168,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40607:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6171,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6169,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40614:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030313265303636653762383339666130353063333039303030303030",
+ "id": 6170,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40619:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_23928895554486018781741056000000_by_1",
+ "typeString": "int_const 23928895554486018781741056000000"
+ },
+ "value": "0x000012e066e7b839fa050c309000000"
+ },
+ "src": "40614:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40607:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6173,
+ "nodeType": "ExpressionStatement",
+ "src": "40607:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6181,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6174,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40689:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6180,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6177,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6175,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40695:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6176,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40700:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40695:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6178,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40694:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6179,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40707:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40694:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40689:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6182,
+ "nodeType": "ExpressionStatement",
+ "src": "40689:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6187,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6183,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40719:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6186,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6184,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40726:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303165333364376439323663333239613161643161383030303030",
+ "id": 6185,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40731:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2392889555448601878174105600000_by_1",
+ "typeString": "int_const 2392889555448601878174105600000"
+ },
+ "value": "0x000001e33d7d926c329a1ad1a800000"
+ },
+ "src": "40726:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40719:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6188,
+ "nodeType": "ExpressionStatement",
+ "src": "40719:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6196,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6189,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40801:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6195,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6192,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6190,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40807:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6191,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40812:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40807:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6193,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40806:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6194,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40819:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40806:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40801:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6197,
+ "nodeType": "ExpressionStatement",
+ "src": "40801:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6202,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6198,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40831:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6201,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6199,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40838:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303032626565353133626462346136623139623566383030303030",
+ "id": 6200,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40843:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_217535414131691079834009600000_by_1",
+ "typeString": "int_const 217535414131691079834009600000"
+ },
+ "value": "0x0000002bee513bdb4a6b19b5f800000"
+ },
+ "src": "40838:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40831:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6203,
+ "nodeType": "ExpressionStatement",
+ "src": "40831:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6211,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6204,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40913:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6210,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6207,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6205,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40919:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6206,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "40924:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40919:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6208,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "40918:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6209,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "40931:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "40918:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40913:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6212,
+ "nodeType": "ExpressionStatement",
+ "src": "40913:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6217,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6213,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "40943:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6216,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6214,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "40950:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030336139333136666137396238386563636632613030303030",
+ "id": 6215,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "40955:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_18127951177640923319500800000_by_1",
+ "typeString": "int_const 18127951177640923319500800000"
+ },
+ "value": "0x00000003a9316fa79b88eccf2a00000"
+ },
+ "src": "40950:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "40943:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6218,
+ "nodeType": "ExpressionStatement",
+ "src": "40943:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6226,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6219,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41025:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6225,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6222,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6220,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41031:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6221,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41036:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41031:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6223,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41030:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6224,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41043:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41030:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41025:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6227,
+ "nodeType": "ExpressionStatement",
+ "src": "41025:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6232,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6228,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41055:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6231,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6229,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41062:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303438313737656265316661383132333735323030303030",
+ "id": 6230,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41067:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1394457782895455639961600000_by_1",
+ "typeString": "int_const 1394457782895455639961600000"
+ },
+ "value": "0x0000000048177ebe1fa812375200000"
+ },
+ "src": "41062:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41055:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6233,
+ "nodeType": "ExpressionStatement",
+ "src": "41055:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6241,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6234,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41137:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6240,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6237,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6235,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41143:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6236,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41148:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41143:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6238,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41142:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6239,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41155:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41142:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41137:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6242,
+ "nodeType": "ExpressionStatement",
+ "src": "41137:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6247,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6243,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41167:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6246,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6244,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41174:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303035323633666539303234326463626163663030303030",
+ "id": 6245,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41179:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_99604127349675402854400000_by_1",
+ "typeString": "int_const 99604127349675402854400000"
+ },
+ "value": "0x0000000005263fe90242dcbacf00000"
+ },
+ "src": "41174:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41167:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6248,
+ "nodeType": "ExpressionStatement",
+ "src": "41167:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6256,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6249,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41249:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6255,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6252,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6250,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41255:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6251,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41260:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41255:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6253,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41254:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6254,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41267:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41254:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41249:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6257,
+ "nodeType": "ExpressionStatement",
+ "src": "41249:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6262,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6258,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41279:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6261,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6259,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41286:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030353765323230393963303330643934313030303030",
+ "id": 6260,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41291:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6640275156645026856960000_by_1",
+ "typeString": "int_const 6640275156645026856960000"
+ },
+ "value": "0x000000000057e22099c030d94100000"
+ },
+ "src": "41286:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41279:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6263,
+ "nodeType": "ExpressionStatement",
+ "src": "41279:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6271,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6264,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41361:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6270,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6267,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6265,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41367:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6266,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41372:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41367:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6268,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41366:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6269,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41379:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41366:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41361:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6272,
+ "nodeType": "ExpressionStatement",
+ "src": "41361:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6277,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6273,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41391:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6276,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6274,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41398:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303537653232303939633033306439343130303030",
+ "id": 6275,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41403:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_415017197290314178560000_by_1",
+ "typeString": "int_const 415017197290314178560000"
+ },
+ "value": "0x0000000000057e22099c030d9410000"
+ },
+ "src": "41398:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41391:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6278,
+ "nodeType": "ExpressionStatement",
+ "src": "41391:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6286,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6279,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41473:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6285,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6282,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6280,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41479:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6281,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41484:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41479:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6283,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41478:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6284,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41491:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41478:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41473:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6287,
+ "nodeType": "ExpressionStatement",
+ "src": "41473:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6292,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6288,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41503:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6291,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6289,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41510:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303035326236623534353639393736333130303030",
+ "id": 6290,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41515:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_24412776311194951680000_by_1",
+ "typeString": "int_const 24412776311194951680000"
+ },
+ "value": "0x00000000000052b6b54569976310000"
+ },
+ "src": "41510:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41503:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6293,
+ "nodeType": "ExpressionStatement",
+ "src": "41503:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6301,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6294,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41585:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6300,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6297,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6295,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41591:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6296,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41596:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41591:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6298,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41590:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6299,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41603:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41590:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41585:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6302,
+ "nodeType": "ExpressionStatement",
+ "src": "41585:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6307,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6303,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41615:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6306,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6304,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41622:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030343938356636373639366266373438303030",
+ "id": 6305,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41627:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1356265350621941760000_by_1",
+ "typeString": "int_const 1356265350621941760000"
+ },
+ "value": "0x00000000000004985f67696bf748000"
+ },
+ "src": "41622:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41615:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6308,
+ "nodeType": "ExpressionStatement",
+ "src": "41615:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6316,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6309,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41697:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6315,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6312,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6310,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41703:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6311,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41708:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41703:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6313,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41702:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6314,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41715:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41702:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41697:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6317,
+ "nodeType": "ExpressionStatement",
+ "src": "41697:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6322,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6318,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41727:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6321,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6319,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41734:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303364656131326561393965343938303030",
+ "id": 6320,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41739:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_71382386874839040000_by_1",
+ "typeString": "int_const 71382386874839040000"
+ },
+ "value": "0x000000000000003dea12ea99e498000"
+ },
+ "src": "41734:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41727:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6323,
+ "nodeType": "ExpressionStatement",
+ "src": "41727:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6331,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6324,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41809:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6330,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6327,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6325,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41815:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6326,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41820:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41815:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6328,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41814:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6329,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41827:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41814:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41809:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6332,
+ "nodeType": "ExpressionStatement",
+ "src": "41809:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6337,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6333,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41839:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6336,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6334,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41846:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303033313838306632323134623665303030",
+ "id": 6335,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41851:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3569119343741952000_by_1",
+ "typeString": "int_const 3569119343741952000"
+ },
+ "value": "0x00000000000000031880f2214b6e000"
+ },
+ "src": "41846:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41839:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6338,
+ "nodeType": "ExpressionStatement",
+ "src": "41839:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6346,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6339,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41921:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6345,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6342,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6340,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41927:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6341,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "41932:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41927:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6343,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "41926:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6344,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "41939:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "41926:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41921:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6347,
+ "nodeType": "ExpressionStatement",
+ "src": "41921:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6352,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6348,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "41951:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6351,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6349,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "41958:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030323562636666353665623336303030",
+ "id": 6350,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "41963:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_169958063987712000_by_1",
+ "typeString": "int_const 169958063987712000"
+ },
+ "value": "0x000000000000000025bcff56eb36000"
+ },
+ "src": "41958:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "41951:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6353,
+ "nodeType": "ExpressionStatement",
+ "src": "41951:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6361,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6354,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42033:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6360,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6357,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6355,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42039:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6356,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42044:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42039:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6358,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42038:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6359,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42051:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42038:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42033:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6362,
+ "nodeType": "ExpressionStatement",
+ "src": "42033:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6367,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6363,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42063:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6366,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6364,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42070:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303162373232653130616231303030",
+ "id": 6365,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42075:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_7725366544896000_by_1",
+ "typeString": "int_const 7725366544896000"
+ },
+ "value": "0x000000000000000001b722e10ab1000"
+ },
+ "src": "42070:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42063:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6368,
+ "nodeType": "ExpressionStatement",
+ "src": "42063:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6376,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6369,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42145:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6375,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6372,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6370,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42151:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6371,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42156:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42151:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6373,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42150:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6374,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42163:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42150:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42145:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6377,
+ "nodeType": "ExpressionStatement",
+ "src": "42145:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6382,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6378,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42175:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6381,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6379,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42182:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303031333137633730303737303030",
+ "id": 6380,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42187:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_335885501952000_by_1",
+ "typeString": "int_const 335885501952000"
+ },
+ "value": "0x0000000000000000001317c70077000"
+ },
+ "src": "42182:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42175:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6383,
+ "nodeType": "ExpressionStatement",
+ "src": "42175:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6391,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6384,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42257:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6390,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6387,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6385,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42263:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6386,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42268:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42263:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6388,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42262:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6389,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42275:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42262:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42257:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6392,
+ "nodeType": "ExpressionStatement",
+ "src": "42257:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6397,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6393,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42287:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6396,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6394,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42294:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030306362613834616166613030",
+ "id": 6395,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42299:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_13995229248000_by_1",
+ "typeString": "int_const 13995229248000"
+ },
+ "value": "0x00000000000000000000cba84aafa00"
+ },
+ "src": "42294:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42287:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6398,
+ "nodeType": "ExpressionStatement",
+ "src": "42287:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6406,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6399,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42369:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6405,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6402,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6400,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42375:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6401,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42380:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42375:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6403,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42374:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6404,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42387:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42374:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42369:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6407,
+ "nodeType": "ExpressionStatement",
+ "src": "42369:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6412,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6408,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42399:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6411,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6409,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42406:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303038323537336130613030",
+ "id": 6410,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42411:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_559809169920_by_1",
+ "typeString": "int_const 559809169920"
+ },
+ "value": "0x00000000000000000000082573a0a00"
+ },
+ "src": "42406:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42399:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6413,
+ "nodeType": "ExpressionStatement",
+ "src": "42399:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6421,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6414,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42481:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6420,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6417,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6415,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42487:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6416,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42492:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42487:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6418,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42486:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6419,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42499:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42486:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42481:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6422,
+ "nodeType": "ExpressionStatement",
+ "src": "42481:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6427,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6423,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42511:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6426,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6424,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42518:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303030353033356164393030",
+ "id": 6425,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42523:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_21531121920_by_1",
+ "typeString": "int_const 21531121920"
+ },
+ "value": "0x00000000000000000000005035ad900"
+ },
+ "src": "42518:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42511:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6428,
+ "nodeType": "ExpressionStatement",
+ "src": "42511:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6436,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6429,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42593:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6435,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6432,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6430,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42599:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6431,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42604:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42599:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6433,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42598:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6434,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42611:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42598:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42593:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6437,
+ "nodeType": "ExpressionStatement",
+ "src": "42593:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6442,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6438,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42623:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6441,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6439,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42630:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303030303266383831623030",
+ "id": 6440,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42635:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_797448960_by_1",
+ "typeString": "int_const 797448960"
+ },
+ "value": "0x000000000000000000000002f881b00"
+ },
+ "src": "42630:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42623:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6443,
+ "nodeType": "ExpressionStatement",
+ "src": "42623:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6451,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6444,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42705:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6450,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6447,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6445,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42711:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6446,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42716:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42711:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6448,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42710:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6449,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42723:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42710:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42705:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6452,
+ "nodeType": "ExpressionStatement",
+ "src": "42705:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6457,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6453,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42735:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6456,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6454,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42742:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303030303031623239333430",
+ "id": 6455,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42747:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_28480320_by_1",
+ "typeString": "int_const 28480320"
+ },
+ "value": "0x0000000000000000000000001b29340"
+ },
+ "src": "42742:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42735:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6458,
+ "nodeType": "ExpressionStatement",
+ "src": "42735:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6466,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6459,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42817:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6465,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6462,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6460,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42823:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6461,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42828:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42823:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6463,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42822:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6464,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42835:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42822:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42817:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6467,
+ "nodeType": "ExpressionStatement",
+ "src": "42817:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6472,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6468,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42847:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6471,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6469,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42854:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303030303030306566633430",
+ "id": 6470,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42859:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_982080_by_1",
+ "typeString": "int_const 982080"
+ },
+ "value": "0x00000000000000000000000000efc40"
+ },
+ "src": "42854:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42847:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6473,
+ "nodeType": "ExpressionStatement",
+ "src": "42847:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6481,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6474,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42929:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6480,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6477,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6475,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42935:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6476,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "42940:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42935:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6478,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "42934:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6479,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "42947:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "42934:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42929:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6482,
+ "nodeType": "ExpressionStatement",
+ "src": "42929:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6487,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6483,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "42959:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6486,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6484,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "42966:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303030303030303037666530",
+ "id": 6485,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "42971:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_32736_by_1",
+ "typeString": "int_const 32736"
+ },
+ "value": "0x0000000000000000000000000007fe0"
+ },
+ "src": "42966:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "42959:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6488,
+ "nodeType": "ExpressionStatement",
+ "src": "42959:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6496,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6489,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43041:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6495,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6492,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6490,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43047:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6491,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "43052:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43047:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6493,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "43046:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6494,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "43059:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "43046:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43041:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6497,
+ "nodeType": "ExpressionStatement",
+ "src": "43041:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6502,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6498,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "43071:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6501,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6499,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43078:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303030303030303030343230",
+ "id": 6500,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "43083:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1056_by_1",
+ "typeString": "int_const 1056"
+ },
+ "value": "0x0000000000000000000000000000420"
+ },
+ "src": "43078:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43071:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6503,
+ "nodeType": "ExpressionStatement",
+ "src": "43071:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6511,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6504,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43153:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6510,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6507,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6505,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43159:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6506,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "43164:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43159:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6508,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "43158:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6509,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "43171:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "43158:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43153:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6512,
+ "nodeType": "ExpressionStatement",
+ "src": "43153:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6517,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6513,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "43183:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6516,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6514,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43190:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303030303030303030303231",
+ "id": 6515,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "43195:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_33_by_1",
+ "typeString": "int_const 33"
+ },
+ "value": "0x0000000000000000000000000000021"
+ },
+ "src": "43190:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43183:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6518,
+ "nodeType": "ExpressionStatement",
+ "src": "43183:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6526,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6519,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43265:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6525,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6522,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6520,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43271:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6521,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "43276:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43271:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6523,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "43270:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6524,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "43283:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "43270:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43265:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6527,
+ "nodeType": "ExpressionStatement",
+ "src": "43265:28:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6532,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6528,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "43295:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6531,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6529,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6047,
+ "src": "43302:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303030303030303030303030303030303031",
+ "id": 6530,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "43307:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "0x0000000000000000000000000000001"
+ },
+ "src": "43302:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43295:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6533,
+ "nodeType": "ExpressionStatement",
+ "src": "43295:45:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6543,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6538,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6536,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6534,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6051,
+ "src": "43386:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307836383835383963633065393530356532663266656535353830303030303030",
+ "id": 6535,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "43392:33:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_8683317618811886495518194401280000000_by_1",
+ "typeString": "int_const 8683...(29 digits omitted)...0000"
+ },
+ "value": "0x688589cc0e9505e2f2fee5580000000"
+ },
+ "src": "43386:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6537,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6039,
+ "src": "43428:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43386:44:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6541,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6539,
+ "name": "ONE",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3574,
+ "src": "43434:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6540,
+ "name": "_precision",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6041,
+ "src": "43441:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "43434:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6542,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "43433:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "43386:66:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 6045,
+ "id": 6544,
+ "nodeType": "Return",
+ "src": "43379:73:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 6037,
+ "nodeType": "StructuredDocumentation",
+ "src": "39082:558:7",
+ "text": " @dev this function can be auto-generated by the script 'PrintFunctionGeneralExp.py'.\n it approximates \"e ^ x\" via maclaurin summation: \"(x^0)/0! + (x^1)/1! + ... + (x^n)/n!\".\n it returns \"e ^ (x / 2 ^ precision) * 2 ^ precision\", that is, the result is upshifted for accuracy.\n the global \"maxExpArray\" maps each \"precision\" to \"((maximumExponent + 1) << (MAX_PRECISION - precision)) - 1\".\n the maximum permitted value for \"x\" is therefore given by \"maxExpArray[precision] >> (MAX_PRECISION - precision)\"."
+ },
+ "id": 6546,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "generalExp",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 6042,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 6039,
+ "mutability": "mutable",
+ "name": "_x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6546,
+ "src": "39666:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6038,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "39666:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 6041,
+ "mutability": "mutable",
+ "name": "_precision",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6546,
+ "src": "39678:16:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 6040,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "39678:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "39665:30:7"
+ },
+ "returnParameters": {
+ "id": 6045,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 6044,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6546,
+ "src": "39719:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6043,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "39719:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "39718:9:7"
+ },
+ "scope": 8977,
+ "src": "39646:3864:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 6865,
+ "nodeType": "Block",
+ "src": "44315:2735:7",
+ "statements": [
+ {
+ "assignments": [
+ 6555
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6555,
+ "mutability": "mutable",
+ "name": "res",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6865,
+ "src": "44326:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6554,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "44326:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6557,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 6556,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44340:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "44326:15:7"
+ },
+ {
+ "assignments": [
+ 6559
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6559,
+ "mutability": "mutable",
+ "name": "y",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6865,
+ "src": "44354:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6558,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "44354:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6560,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "44354:9:7"
+ },
+ {
+ "assignments": [
+ 6562
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6562,
+ "mutability": "mutable",
+ "name": "z",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6865,
+ "src": "44374:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6561,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "44374:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6563,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "44374:9:7"
+ },
+ {
+ "assignments": [
+ 6565
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6565,
+ "mutability": "mutable",
+ "name": "w",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6865,
+ "src": "44394:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6564,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "44394:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6566,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "44394:9:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6569,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6567,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44420:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30786433303934633730663033346465346239366666376435623666393966636438",
+ "id": 6568,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44425:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_280515388193368458015406427511040113880_by_1",
+ "typeString": "int_const 2805...(31 digits omitted)...3880"
+ },
+ "value": "0xd3094c70f034de4b96ff7d5b6f99fcd8"
+ },
+ "src": "44420:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6583,
+ "nodeType": "IfStatement",
+ "src": "44416:143:7",
+ "trueBody": {
+ "id": 6582,
+ "nodeType": "Block",
+ "src": "44461:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6572,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6570,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "44462:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783430303030303030303030303030303030303030303030303030303030303030",
+ "id": 6571,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44469:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_85070591730234615865843651857942052864_by_1",
+ "typeString": "int_const 8507...(30 digits omitted)...2864"
+ },
+ "value": "0x40000000000000000000000000000000"
+ },
+ "src": "44462:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6573,
+ "nodeType": "ExpressionStatement",
+ "src": "44462:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6580,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6574,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44505:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6579,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6577,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6575,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44509:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6576,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "44513:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "44509:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30786433303934633730663033346465346239366666376435623666393966636438",
+ "id": 6578,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44523:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_280515388193368458015406427511040113880_by_1",
+ "typeString": "int_const 2805...(31 digits omitted)...3880"
+ },
+ "value": "0xd3094c70f034de4b96ff7d5b6f99fcd8"
+ },
+ "src": "44509:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "44505:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6581,
+ "nodeType": "ExpressionStatement",
+ "src": "44505:52:7"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6586,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6584,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44588:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30786134356166316531663430633333336233646531646234646435356632396137",
+ "id": 6585,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44593:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_218465603988574474844591417643679820199_by_1",
+ "typeString": "int_const 2184...(31 digits omitted)...0199"
+ },
+ "value": "0xa45af1e1f40c333b3de1db4dd55f29a7"
+ },
+ "src": "44588:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6600,
+ "nodeType": "IfStatement",
+ "src": "44584:143:7",
+ "trueBody": {
+ "id": 6599,
+ "nodeType": "Block",
+ "src": "44629:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6589,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6587,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "44630:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783230303030303030303030303030303030303030303030303030303030303030",
+ "id": 6588,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44637:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_42535295865117307932921825928971026432_by_1",
+ "typeString": "int_const 4253...(30 digits omitted)...6432"
+ },
+ "value": "0x20000000000000000000000000000000"
+ },
+ "src": "44630:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6590,
+ "nodeType": "ExpressionStatement",
+ "src": "44630:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6597,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6591,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44673:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6596,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6594,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6592,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44677:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6593,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "44681:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "44677:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30786134356166316531663430633333336233646531646234646435356632396137",
+ "id": 6595,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44691:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_218465603988574474844591417643679820199_by_1",
+ "typeString": "int_const 2184...(31 digits omitted)...0199"
+ },
+ "value": "0xa45af1e1f40c333b3de1db4dd55f29a7"
+ },
+ "src": "44677:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "44673:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6598,
+ "nodeType": "ExpressionStatement",
+ "src": "44673:52:7"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6603,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6601,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44756:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783931306230323264623761653637636537366234343163323730333563366131",
+ "id": 6602,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44761:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_192795218841189805222451540510555621025_by_1",
+ "typeString": "int_const 1927...(31 digits omitted)...1025"
+ },
+ "value": "0x910b022db7ae67ce76b441c27035c6a1"
+ },
+ "src": "44756:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6617,
+ "nodeType": "IfStatement",
+ "src": "44752:143:7",
+ "trueBody": {
+ "id": 6616,
+ "nodeType": "Block",
+ "src": "44797:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6606,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6604,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "44798:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783130303030303030303030303030303030303030303030303030303030303030",
+ "id": 6605,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44805:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_21267647932558653966460912964485513216_by_1",
+ "typeString": "int_const 2126...(30 digits omitted)...3216"
+ },
+ "value": "0x10000000000000000000000000000000"
+ },
+ "src": "44798:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6607,
+ "nodeType": "ExpressionStatement",
+ "src": "44798:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6614,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6608,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44841:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6613,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6611,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6609,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44845:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6610,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "44849:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "44845:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783931306230323264623761653637636537366234343163323730333563366131",
+ "id": 6612,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44859:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_192795218841189805222451540510555621025_by_1",
+ "typeString": "int_const 1927...(31 digits omitted)...1025"
+ },
+ "value": "0x910b022db7ae67ce76b441c27035c6a1"
+ },
+ "src": "44845:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "44841:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6615,
+ "nodeType": "ExpressionStatement",
+ "src": "44841:52:7"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6620,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6618,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "44924:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783838343135616262653961373662656164386430306366313132653464346138",
+ "id": 6619,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44929:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_181114347027396448854165353426875372712_by_1",
+ "typeString": "int_const 1811...(31 digits omitted)...2712"
+ },
+ "value": "0x88415abbe9a76bead8d00cf112e4d4a8"
+ },
+ "src": "44924:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6634,
+ "nodeType": "IfStatement",
+ "src": "44920:143:7",
+ "trueBody": {
+ "id": 6633,
+ "nodeType": "Block",
+ "src": "44965:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6623,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6621,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "44966:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783038303030303030303030303030303030303030303030303030303030303030",
+ "id": 6622,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "44973:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_10633823966279326983230456482242756608_by_1",
+ "typeString": "int_const 1063...(30 digits omitted)...6608"
+ },
+ "value": "0x08000000000000000000000000000000"
+ },
+ "src": "44966:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6624,
+ "nodeType": "ExpressionStatement",
+ "src": "44966:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6631,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6625,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45009:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6630,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6628,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6626,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45013:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6627,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "45017:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45013:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783838343135616262653961373662656164386430306366313132653464346138",
+ "id": 6629,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45027:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_181114347027396448854165353426875372712_by_1",
+ "typeString": "int_const 1811...(31 digits omitted)...2712"
+ },
+ "value": "0x88415abbe9a76bead8d00cf112e4d4a8"
+ },
+ "src": "45013:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45009:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6632,
+ "nodeType": "ExpressionStatement",
+ "src": "45009:52:7"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6637,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6635,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45092:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783834313032623030383933663634633730356538343164356434303634626433",
+ "id": 6636,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45097:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_175542044379434494067323265867529472979_by_1",
+ "typeString": "int_const 1755...(31 digits omitted)...2979"
+ },
+ "value": "0x84102b00893f64c705e841d5d4064bd3"
+ },
+ "src": "45092:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6651,
+ "nodeType": "IfStatement",
+ "src": "45088:143:7",
+ "trueBody": {
+ "id": 6650,
+ "nodeType": "Block",
+ "src": "45133:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6640,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6638,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "45134:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783034303030303030303030303030303030303030303030303030303030303030",
+ "id": 6639,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45141:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_5316911983139663491615228241121378304_by_1",
+ "typeString": "int_const 5316...(29 digits omitted)...8304"
+ },
+ "value": "0x04000000000000000000000000000000"
+ },
+ "src": "45134:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6641,
+ "nodeType": "ExpressionStatement",
+ "src": "45134:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6648,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6642,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45177:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6647,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6645,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6643,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45181:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6644,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "45185:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45181:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783834313032623030383933663634633730356538343164356434303634626433",
+ "id": 6646,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45195:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_175542044379434494067323265867529472979_by_1",
+ "typeString": "int_const 1755...(31 digits omitted)...2979"
+ },
+ "value": "0x84102b00893f64c705e841d5d4064bd3"
+ },
+ "src": "45181:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45177:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6649,
+ "nodeType": "ExpressionStatement",
+ "src": "45177:52:7"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6654,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6652,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45260:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783832303430353561616566316338626435633332353966343832323733356132",
+ "id": 6653,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45265:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_172820517236198538127967385733353125282_by_1",
+ "typeString": "int_const 1728...(31 digits omitted)...5282"
+ },
+ "value": "0x8204055aaef1c8bd5c3259f4822735a2"
+ },
+ "src": "45260:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6668,
+ "nodeType": "IfStatement",
+ "src": "45256:143:7",
+ "trueBody": {
+ "id": 6667,
+ "nodeType": "Block",
+ "src": "45301:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6657,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6655,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "45302:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783032303030303030303030303030303030303030303030303030303030303030",
+ "id": 6656,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45309:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2658455991569831745807614120560689152_by_1",
+ "typeString": "int_const 2658...(29 digits omitted)...9152"
+ },
+ "value": "0x02000000000000000000000000000000"
+ },
+ "src": "45302:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6658,
+ "nodeType": "ExpressionStatement",
+ "src": "45302:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6665,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6659,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45345:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6664,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6662,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6660,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45349:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6661,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "45353:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45349:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783832303430353561616566316338626435633332353966343832323733356132",
+ "id": 6663,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45363:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_172820517236198538127967385733353125282_by_1",
+ "typeString": "int_const 1728...(31 digits omitted)...5282"
+ },
+ "value": "0x8204055aaef1c8bd5c3259f4822735a2"
+ },
+ "src": "45349:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45345:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6666,
+ "nodeType": "ExpressionStatement",
+ "src": "45345:52:7"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6671,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6669,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45428:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783831303130306162303032323264383631393331633135653339623434653939",
+ "id": 6670,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45433:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_171475617301169790829459146906809945753_by_1",
+ "typeString": "int_const 1714...(31 digits omitted)...5753"
+ },
+ "value": "0x810100ab00222d861931c15e39b44e99"
+ },
+ "src": "45428:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6685,
+ "nodeType": "IfStatement",
+ "src": "45424:143:7",
+ "trueBody": {
+ "id": 6684,
+ "nodeType": "Block",
+ "src": "45469:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6674,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6672,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "45470:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783031303030303030303030303030303030303030303030303030303030303030",
+ "id": 6673,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45477:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1329227995784915872903807060280344576_by_1",
+ "typeString": "int_const 1329...(29 digits omitted)...4576"
+ },
+ "value": "0x01000000000000000000000000000000"
+ },
+ "src": "45470:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6675,
+ "nodeType": "ExpressionStatement",
+ "src": "45470:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6682,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6676,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45513:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6681,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6679,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6677,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45517:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6678,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "45521:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45517:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783831303130306162303032323264383631393331633135653339623434653939",
+ "id": 6680,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45531:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_171475617301169790829459146906809945753_by_1",
+ "typeString": "int_const 1714...(31 digits omitted)...5753"
+ },
+ "value": "0x810100ab00222d861931c15e39b44e99"
+ },
+ "src": "45517:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45513:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6683,
+ "nodeType": "ExpressionStatement",
+ "src": "45513:52:7"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6688,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6686,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45596:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783830383034303135356161626262653934353135323136393335353466373333",
+ "id": 6687,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45601:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_170807097224429000759274174605493073715_by_1",
+ "typeString": "int_const 1708...(31 digits omitted)...3715"
+ },
+ "value": "0x808040155aabbbe9451521693554f733"
+ },
+ "src": "45596:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 6702,
+ "nodeType": "IfStatement",
+ "src": "45592:143:7",
+ "trueBody": {
+ "id": 6701,
+ "nodeType": "Block",
+ "src": "45637:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6691,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6689,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "45638:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30783030383030303030303030303030303030303030303030303030303030303030",
+ "id": 6690,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45645:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_664613997892457936451903530140172288_by_1",
+ "typeString": "int_const 6646...(28 digits omitted)...2288"
+ },
+ "value": "0x00800000000000000000000000000000"
+ },
+ "src": "45638:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6692,
+ "nodeType": "ExpressionStatement",
+ "src": "45638:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6699,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6693,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45681:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6698,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6696,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6694,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45685:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6695,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "45689:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45685:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783830383034303135356161626262653934353135323136393335353466373333",
+ "id": 6697,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45699:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_170807097224429000759274174605493073715_by_1",
+ "typeString": "int_const 1708...(31 digits omitted)...3715"
+ },
+ "value": "0x808040155aabbbe9451521693554f733"
+ },
+ "src": "45685:48:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45681:52:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6700,
+ "nodeType": "ExpressionStatement",
+ "src": "45681:52:7"
+ }
+ ]
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6709,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6703,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "45762:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 6708,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6704,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "45766:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6707,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6705,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6549,
+ "src": "45770:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6706,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "45774:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45770:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45766:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45762:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6710,
+ "nodeType": "ExpressionStatement",
+ "src": "45762:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6717,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6711,
+ "name": "w",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6565,
+ "src": "45792:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6716,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6714,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6712,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "45796:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6713,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "45800:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45796:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6715,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "45804:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45796:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45792:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6718,
+ "nodeType": "ExpressionStatement",
+ "src": "45792:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6728,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6719,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "45822:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6727,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6725,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6720,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "45829:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6723,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078313030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6721,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45834:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_340282366920938463463374607431768211456_by_1",
+ "typeString": "int_const 3402...(31 digits omitted)...1456"
+ },
+ "value": "0x100000000000000000000000000000000"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6722,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "45872:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45834:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6724,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "45833:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45829:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078313030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6726,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45877:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_340282366920938463463374607431768211456_by_1",
+ "typeString": "int_const 3402...(31 digits omitted)...1456"
+ },
+ "value": "0x100000000000000000000000000000000"
+ },
+ "src": "45829:83:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45822:90:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6729,
+ "nodeType": "ExpressionStatement",
+ "src": "45822:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6736,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6730,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "45914:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6735,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6733,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6731,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "45918:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6732,
+ "name": "w",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6565,
+ "src": "45922:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45918:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6734,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "45926:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45918:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45914:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6737,
+ "nodeType": "ExpressionStatement",
+ "src": "45914:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6747,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6738,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "45973:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6746,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6744,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6739,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "45980:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6742,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078306161616161616161616161616161616161616161616161616161616161616161",
+ "id": 6740,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "45985:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_226854911280625642308916404954512140970_by_1",
+ "typeString": "int_const 2268...(31 digits omitted)...0970"
+ },
+ "value": "0x0aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6741,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "46023:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45985:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6743,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "45984:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45980:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078323030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6745,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46028:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_680564733841876926926749214863536422912_by_1",
+ "typeString": "int_const 6805...(31 digits omitted)...2912"
+ },
+ "value": "0x200000000000000000000000000000000"
+ },
+ "src": "45980:83:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "45973:90:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6748,
+ "nodeType": "ExpressionStatement",
+ "src": "45973:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6755,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6749,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46065:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6754,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6752,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6750,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46069:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6751,
+ "name": "w",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6565,
+ "src": "46073:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46069:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6753,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "46077:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46069:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46065:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6756,
+ "nodeType": "ExpressionStatement",
+ "src": "46065:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6766,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6757,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "46124:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6765,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6763,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6758,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46131:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6761,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303939393939393939393939393939393939393939393939393939393939393939",
+ "id": 6759,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46136:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_204169420152563078078024764459060926873_by_1",
+ "typeString": "int_const 2041...(31 digits omitted)...6873"
+ },
+ "value": "0x099999999999999999999999999999999"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6760,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "46174:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46136:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6762,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "46135:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46131:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078333030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6764,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46179:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1020847100762815390390123822295304634368_by_1",
+ "typeString": "int_const 1020...(32 digits omitted)...4368"
+ },
+ "value": "0x300000000000000000000000000000000"
+ },
+ "src": "46131:83:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46124:90:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6767,
+ "nodeType": "ExpressionStatement",
+ "src": "46124:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6774,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6768,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46216:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6773,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6771,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6769,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46220:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6770,
+ "name": "w",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6565,
+ "src": "46224:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46220:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6772,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "46228:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46220:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46216:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6775,
+ "nodeType": "ExpressionStatement",
+ "src": "46216:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6785,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6776,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "46275:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6784,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6782,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6777,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46282:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6780,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303932343932343932343932343932343932343932343932343932343932343932",
+ "id": 6778,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46287:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_194447066811964836264785489961010406546_by_1",
+ "typeString": "int_const 1944...(31 digits omitted)...6546"
+ },
+ "value": "0x092492492492492492492492492492492"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6779,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "46325:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46287:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6781,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "46286:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46282:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078343030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6783,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46330:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1361129467683753853853498429727072845824_by_1",
+ "typeString": "int_const 1361...(32 digits omitted)...5824"
+ },
+ "value": "0x400000000000000000000000000000000"
+ },
+ "src": "46282:83:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46275:90:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6786,
+ "nodeType": "ExpressionStatement",
+ "src": "46275:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6793,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6787,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46367:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6792,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6790,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6788,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46371:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6789,
+ "name": "w",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6565,
+ "src": "46375:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46371:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6791,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "46379:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46371:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46367:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6794,
+ "nodeType": "ExpressionStatement",
+ "src": "46367:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6804,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6795,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "46426:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6803,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6801,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6796,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46433:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6799,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303865333865333865333865333865333865333865333865333865333865333865",
+ "id": 6797,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46438:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_189045759400521368590763670795426784142_by_1",
+ "typeString": "int_const 1890...(31 digits omitted)...4142"
+ },
+ "value": "0x08e38e38e38e38e38e38e38e38e38e38e"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6798,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "46476:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46438:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6800,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "46437:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46433:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078353030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6802,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46481:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1701411834604692317316873037158841057280_by_1",
+ "typeString": "int_const 1701...(32 digits omitted)...7280"
+ },
+ "value": "0x500000000000000000000000000000000"
+ },
+ "src": "46433:83:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46426:90:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6805,
+ "nodeType": "ExpressionStatement",
+ "src": "46426:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6812,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6806,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46518:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6811,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6809,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6807,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46522:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6808,
+ "name": "w",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6565,
+ "src": "46526:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46522:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6810,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "46530:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46522:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46518:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6813,
+ "nodeType": "ExpressionStatement",
+ "src": "46518:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6823,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6814,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "46577:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6822,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6820,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6815,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46584:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6818,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303862613265386261326538626132653862613265386261326538626132653862",
+ "id": 6816,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46589:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_185608563775057343707295240417328115339_by_1",
+ "typeString": "int_const 1856...(31 digits omitted)...5339"
+ },
+ "value": "0x08ba2e8ba2e8ba2e8ba2e8ba2e8ba2e8b"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6817,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "46627:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46589:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6819,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "46588:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46584:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078363030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6821,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46632:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2041694201525630780780247644590609268736_by_1",
+ "typeString": "int_const 2041...(32 digits omitted)...8736"
+ },
+ "value": "0x600000000000000000000000000000000"
+ },
+ "src": "46584:83:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46577:90:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6824,
+ "nodeType": "ExpressionStatement",
+ "src": "46577:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6831,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6825,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46669:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6830,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6828,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6826,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46673:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6827,
+ "name": "w",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6565,
+ "src": "46677:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46673:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6829,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "46681:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46673:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46669:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6832,
+ "nodeType": "ExpressionStatement",
+ "src": "46669:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6842,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6833,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "46728:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6841,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6839,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6834,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46735:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6837,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303839643839643839643839643839643839643839643839643839643839643839",
+ "id": 6835,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46740:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_183228966803582249557201711694029036937_by_1",
+ "typeString": "int_const 1832...(31 digits omitted)...6937"
+ },
+ "value": "0x089d89d89d89d89d89d89d89d89d89d89"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6836,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "46778:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46740:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6838,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "46739:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46735:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078373030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6840,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46783:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2381976568446569244243622252022377480192_by_1",
+ "typeString": "int_const 2381...(32 digits omitted)...0192"
+ },
+ "value": "0x700000000000000000000000000000000"
+ },
+ "src": "46735:83:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46728:90:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6843,
+ "nodeType": "ExpressionStatement",
+ "src": "46728:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6850,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6844,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46820:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6849,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6847,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6845,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46824:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6846,
+ "name": "w",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6565,
+ "src": "46828:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46824:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6848,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "46832:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46824:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46820:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6851,
+ "nodeType": "ExpressionStatement",
+ "src": "46820:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6861,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6852,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "46879:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6860,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6858,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6853,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6562,
+ "src": "46886:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6856,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303838383838383838383838383838383838383838383838383838383838383838",
+ "id": 6854,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46891:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_181483929024500513847133123963609712776_by_1",
+ "typeString": "int_const 1814...(31 digits omitted)...2776"
+ },
+ "value": "0x088888888888888888888888888888888"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6855,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6559,
+ "src": "46929:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46891:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 6857,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "46890:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46886:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078383030303030303030303030303030303030303030303030303030303030303030",
+ "id": 6859,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "46934:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2722258935367507707706996859454145691648_by_1",
+ "typeString": "int_const 2722...(32 digits omitted)...1648"
+ },
+ "value": "0x800000000000000000000000000000000"
+ },
+ "src": "46886:83:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "46879:90:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6862,
+ "nodeType": "ExpressionStatement",
+ "src": "46879:90:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6863,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6555,
+ "src": "47039:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 6553,
+ "id": 6864,
+ "nodeType": "Return",
+ "src": "47032:10:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 6547,
+ "nodeType": "StructuredDocumentation",
+ "src": "43518:728:7",
+ "text": " @dev computes log(x / FIXED_1) * FIXED_1\n Input range: FIXED_1 <= x <= OPT_LOG_MAX_VAL - 1\n Auto-generated via 'PrintFunctionOptimalLog.py'\n Detailed description:\n - Rewrite the input as a product of natural exponents and a single residual r, such that 1 < r < 2\n - The natural logarithm of each (pre-calculated) exponent is the degree of the exponent\n - The natural logarithm of r is calculated via Taylor series for log(1 + x), where x = r - 1\n - The natural logarithm of the input is calculated by summing up the intermediate results above\n - For example: log(250) = log(e^4 * e^1 * e^0.5 * 1.021692859) = 4 + 1 + 0.5 + log(1 + 0.021692859)"
+ },
+ "id": 6866,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "optimalLog",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 6550,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 6549,
+ "mutability": "mutable",
+ "name": "x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6866,
+ "src": "44272:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6548,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "44272:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "44271:11:7"
+ },
+ "returnParameters": {
+ "id": 6553,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 6552,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 6866,
+ "src": "44306:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6551,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "44306:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "44305:9:7"
+ },
+ "scope": 8977,
+ "src": "44252:2798:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 7275,
+ "nodeType": "Block",
+ "src": "47810:3153:7",
+ "statements": [
+ {
+ "assignments": [
+ 6875
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6875,
+ "mutability": "mutable",
+ "name": "res",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7275,
+ "src": "47821:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6874,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "47821:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6877,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 6876,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "47835:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "47821:15:7"
+ },
+ {
+ "assignments": [
+ 6879
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6879,
+ "mutability": "mutable",
+ "name": "y",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7275,
+ "src": "47849:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6878,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "47849:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6880,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "47849:9:7"
+ },
+ {
+ "assignments": [
+ 6882
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 6882,
+ "mutability": "mutable",
+ "name": "z",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7275,
+ "src": "47869:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6881,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "47869:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 6883,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "47869:9:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6890,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6884,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "47891:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 6889,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6885,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "47895:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6888,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6886,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6869,
+ "src": "47899:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "%",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30783130303030303030303030303030303030303030303030303030303030303030",
+ "id": 6887,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "47903:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_21267647932558653966460912964485513216_by_1",
+ "typeString": "int_const 2126...(30 digits omitted)...3216"
+ },
+ "value": "0x10000000000000000000000000000000"
+ },
+ "src": "47899:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "47895:42:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "47891:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6891,
+ "nodeType": "ExpressionStatement",
+ "src": "47891:46:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6898,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6892,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "47979:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6897,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6895,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6893,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "47983:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6894,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "47987:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "47983:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6896,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "47991:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "47983:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "47979:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6899,
+ "nodeType": "ExpressionStatement",
+ "src": "47979:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6904,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6900,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48000:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6903,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6901,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48007:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307831306531623362653431356130303030",
+ "id": 6902,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48011:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1216451004088320000_by_1",
+ "typeString": "int_const 1216451004088320000"
+ },
+ "value": "0x10e1b3be415a0000"
+ },
+ "src": "48007:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48000:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6905,
+ "nodeType": "ExpressionStatement",
+ "src": "48000:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6912,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6906,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48066:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6911,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6909,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6907,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48070:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6908,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48074:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48070:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6910,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48078:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48070:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48066:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6913,
+ "nodeType": "ExpressionStatement",
+ "src": "48066:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6918,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6914,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48087:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6917,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6915,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48094:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830356130393133663662316530303030",
+ "id": 6916,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48098:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_405483668029440000_by_1",
+ "typeString": "int_const 405483668029440000"
+ },
+ "value": "0x05a0913f6b1e0000"
+ },
+ "src": "48094:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48087:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6919,
+ "nodeType": "ExpressionStatement",
+ "src": "48087:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6926,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6920,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48153:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6925,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6923,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6921,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48157:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6922,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48161:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48157:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6924,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48165:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48157:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48153:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6927,
+ "nodeType": "ExpressionStatement",
+ "src": "48153:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6932,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6928,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48174:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6931,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6929,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48181:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830313638323434666461633738303030",
+ "id": 6930,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48185:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_101370917007360000_by_1",
+ "typeString": "int_const 101370917007360000"
+ },
+ "value": "0x0168244fdac78000"
+ },
+ "src": "48181:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48174:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6933,
+ "nodeType": "ExpressionStatement",
+ "src": "48174:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6940,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6934,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48240:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6939,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6937,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6935,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48244:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6936,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48248:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48244:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6938,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48252:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48244:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48240:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6941,
+ "nodeType": "ExpressionStatement",
+ "src": "48240:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6946,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6942,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48261:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6945,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6943,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48268:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303438303734333262633138303030",
+ "id": 6944,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48272:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_20274183401472000_by_1",
+ "typeString": "int_const 20274183401472000"
+ },
+ "value": "0x004807432bc18000"
+ },
+ "src": "48268:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48261:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6947,
+ "nodeType": "ExpressionStatement",
+ "src": "48261:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6954,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6948,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48327:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6953,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6951,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6949,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48331:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6950,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48335:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48331:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6952,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48339:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48331:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48327:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6955,
+ "nodeType": "ExpressionStatement",
+ "src": "48327:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6960,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6956,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48348:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6959,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6957,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48355:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303063303133356463613034303030",
+ "id": 6958,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48359:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3379030566912000_by_1",
+ "typeString": "int_const 3379030566912000"
+ },
+ "value": "0x000c0135dca04000"
+ },
+ "src": "48355:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48348:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6961,
+ "nodeType": "ExpressionStatement",
+ "src": "48348:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6968,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6962,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48414:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6967,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6965,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6963,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48418:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6964,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48422:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48418:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6966,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48426:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48418:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48414:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6969,
+ "nodeType": "ExpressionStatement",
+ "src": "48414:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6974,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6970,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48435:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6973,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6971,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48442:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303031623730376231636463303030",
+ "id": 6972,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48446:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_482718652416000_by_1",
+ "typeString": "int_const 482718652416000"
+ },
+ "value": "0x0001b707b1cdc000"
+ },
+ "src": "48442:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48435:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6975,
+ "nodeType": "ExpressionStatement",
+ "src": "48435:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6982,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6976,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48501:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6981,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6979,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6977,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48505:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6978,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48509:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48505:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6980,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48513:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48505:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48501:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6983,
+ "nodeType": "ExpressionStatement",
+ "src": "48501:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6988,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6984,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48522:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6987,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6985,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48529:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030333665306636333962383030",
+ "id": 6986,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48533:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_60339831552000_by_1",
+ "typeString": "int_const 60339831552000"
+ },
+ "value": "0x000036e0f639b800"
+ },
+ "src": "48529:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48522:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6989,
+ "nodeType": "ExpressionStatement",
+ "src": "48522:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 6996,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6990,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48588:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6995,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 6993,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6991,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48592:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6992,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48596:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48592:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 6994,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48600:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48592:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48588:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 6997,
+ "nodeType": "ExpressionStatement",
+ "src": "48588:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7002,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 6998,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48609:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7001,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 6999,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48616:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303631386665653966383030",
+ "id": 7000,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48620:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6704425728000_by_1",
+ "typeString": "int_const 6704425728000"
+ },
+ "value": "0x00000618fee9f800"
+ },
+ "src": "48616:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48609:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7003,
+ "nodeType": "ExpressionStatement",
+ "src": "48609:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7010,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7004,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48675:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7009,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7007,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7005,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48679:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7006,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48683:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48679:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7008,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48687:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48679:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48675:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7011,
+ "nodeType": "ExpressionStatement",
+ "src": "48675:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7016,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7012,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48696:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7015,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7013,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48703:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303039633139376463633030",
+ "id": 7014,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48707:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_670442572800_by_1",
+ "typeString": "int_const 670442572800"
+ },
+ "value": "0x0000009c197dcc00"
+ },
+ "src": "48703:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48696:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7017,
+ "nodeType": "ExpressionStatement",
+ "src": "48696:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7024,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7018,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48762:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7023,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7021,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7019,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48766:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7020,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48770:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48766:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7022,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48774:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48766:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48762:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7025,
+ "nodeType": "ExpressionStatement",
+ "src": "48762:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7030,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7026,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48783:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7029,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7027,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48790:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030653330646365343030",
+ "id": 7028,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48794:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_60949324800_by_1",
+ "typeString": "int_const 60949324800"
+ },
+ "value": "0x0000000e30dce400"
+ },
+ "src": "48790:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48783:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7031,
+ "nodeType": "ExpressionStatement",
+ "src": "48783:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7038,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7032,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48849:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7037,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7035,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7033,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48853:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7034,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48857:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48853:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7036,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48861:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48853:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48849:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7039,
+ "nodeType": "ExpressionStatement",
+ "src": "48849:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7044,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7040,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48870:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7043,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7041,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48877:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030313265626431333030",
+ "id": 7042,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48881:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_5079110400_by_1",
+ "typeString": "int_const 5079110400"
+ },
+ "value": "0x000000012ebd1300"
+ },
+ "src": "48877:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48870:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7045,
+ "nodeType": "ExpressionStatement",
+ "src": "48870:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7052,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7046,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48936:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7051,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7049,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7047,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48940:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7048,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "48944:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48940:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7050,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "48948:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48940:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48936:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7053,
+ "nodeType": "ExpressionStatement",
+ "src": "48936:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7058,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7054,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "48957:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7057,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7055,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "48964:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303137343939663030",
+ "id": 7056,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "48968:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_390700800_by_1",
+ "typeString": "int_const 390700800"
+ },
+ "value": "0x0000000017499f00"
+ },
+ "src": "48964:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "48957:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7059,
+ "nodeType": "ExpressionStatement",
+ "src": "48957:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7066,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7060,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49023:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7065,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7063,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7061,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49027:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7062,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "49031:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49027:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7064,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "49035:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49027:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49023:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7067,
+ "nodeType": "ExpressionStatement",
+ "src": "49023:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7072,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7068,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49044:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7071,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7069,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49051:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303031613964343830",
+ "id": 7070,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49055:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_27907200_by_1",
+ "typeString": "int_const 27907200"
+ },
+ "value": "0x0000000001a9d480"
+ },
+ "src": "49051:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49044:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7073,
+ "nodeType": "ExpressionStatement",
+ "src": "49044:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7080,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7074,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49110:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7079,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7077,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7075,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49114:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7076,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "49118:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49114:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7078,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "49122:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49114:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49110:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7081,
+ "nodeType": "ExpressionStatement",
+ "src": "49110:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7086,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7082,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49131:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7085,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7083,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49138:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030316336333830",
+ "id": 7084,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49142:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1860480_by_1",
+ "typeString": "int_const 1860480"
+ },
+ "value": "0x00000000001c6380"
+ },
+ "src": "49138:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49131:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7087,
+ "nodeType": "ExpressionStatement",
+ "src": "49131:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7094,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7088,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49197:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7093,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7091,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7089,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49201:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7090,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "49205:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49201:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7092,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "49209:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49201:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49197:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7095,
+ "nodeType": "ExpressionStatement",
+ "src": "49197:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7100,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7096,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49218:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7099,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7097,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49225:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303163363338",
+ "id": 7098,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49229:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_116280_by_1",
+ "typeString": "int_const 116280"
+ },
+ "value": "0x000000000001c638"
+ },
+ "src": "49225:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49218:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7101,
+ "nodeType": "ExpressionStatement",
+ "src": "49218:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7108,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7102,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49284:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7107,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7105,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7103,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49288:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7104,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "49292:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49288:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7106,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "49296:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49288:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49284:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7109,
+ "nodeType": "ExpressionStatement",
+ "src": "49284:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7114,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7110,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49305:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7113,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7111,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49312:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303031616238",
+ "id": 7112,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49316:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6840_by_1",
+ "typeString": "int_const 6840"
+ },
+ "value": "0x0000000000001ab8"
+ },
+ "src": "49312:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49305:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7115,
+ "nodeType": "ExpressionStatement",
+ "src": "49305:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7122,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7116,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49371:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7121,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7119,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7117,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49375:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7118,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "49379:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49375:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7120,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "49383:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49375:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49371:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7123,
+ "nodeType": "ExpressionStatement",
+ "src": "49371:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7128,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7124,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49392:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7127,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7125,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49399:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030313763",
+ "id": 7126,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49403:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_380_by_1",
+ "typeString": "int_const 380"
+ },
+ "value": "0x000000000000017c"
+ },
+ "src": "49399:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49392:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7129,
+ "nodeType": "ExpressionStatement",
+ "src": "49392:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7136,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7130,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49458:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7135,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7133,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7131,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49462:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7132,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "49466:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49462:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7134,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "49470:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49462:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49458:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7137,
+ "nodeType": "ExpressionStatement",
+ "src": "49458:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7142,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7138,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49479:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7141,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7139,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49486:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303134",
+ "id": 7140,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49490:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_20_by_1",
+ "typeString": "int_const 20"
+ },
+ "value": "0x0000000000000014"
+ },
+ "src": "49486:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49479:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7143,
+ "nodeType": "ExpressionStatement",
+ "src": "49479:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7150,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7144,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49545:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7149,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7147,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7145,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49549:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7146,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "49553:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49549:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7148,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "49557:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49549:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49545:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7151,
+ "nodeType": "ExpressionStatement",
+ "src": "49545:19:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7156,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7152,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49566:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7155,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7153,
+ "name": "z",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6882,
+ "src": "49573:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307830303030303030303030303030303031",
+ "id": 7154,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49577:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "0x0000000000000001"
+ },
+ "src": "49573:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49566:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7157,
+ "nodeType": "ExpressionStatement",
+ "src": "49566:29:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7166,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7158,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49632:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7165,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7163,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7161,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7159,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49638:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "307832316333363737633832623430303030",
+ "id": 7160,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49644:18:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2432902008176640000_by_1",
+ "typeString": "int_const 2432902008176640000"
+ },
+ "value": "0x21c3677c82b40000"
+ },
+ "src": "49638:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7162,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6879,
+ "src": "49665:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49638:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7164,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "49669:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49638:38:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49632:44:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7167,
+ "nodeType": "ExpressionStatement",
+ "src": "49632:44:7"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7173,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7170,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7168,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6869,
+ "src": "49744:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303130303030303030303030303030303030303030303030303030303030303030",
+ "id": 7169,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49748:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_21267647932558653966460912964485513216_by_1",
+ "typeString": "int_const 2126...(30 digits omitted)...3216"
+ },
+ "value": "0x010000000000000000000000000000000"
+ },
+ "src": "49744:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7171,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "49743:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 7172,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49788:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "49743:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7182,
+ "nodeType": "IfStatement",
+ "src": "49739:137:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7180,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7174,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49791:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7179,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7177,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7175,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49797:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078316333643661323465643832323138373837643632346433653565626139356639",
+ "id": 7176,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49803:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_600596269623765960634066700837880239609_by_1",
+ "typeString": "int_const 6005...(31 digits omitted)...9609"
+ },
+ "value": "0x1c3d6a24ed82218787d624d3e5eba95f9"
+ },
+ "src": "49797:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078313865626566396561633832306165383638326239373933616336643165373736",
+ "id": 7178,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49841:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_530024347646835984032474664511850276726_by_1",
+ "typeString": "int_const 5300...(31 digits omitted)...6726"
+ },
+ "value": "0x18ebef9eac820ae8682b9793ac6d1e776"
+ },
+ "src": "49797:79:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49791:85:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7181,
+ "nodeType": "ExpressionStatement",
+ "src": "49791:85:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7188,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7185,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7183,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6869,
+ "src": "49916:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303230303030303030303030303030303030303030303030303030303030303030",
+ "id": 7184,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49920:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_42535295865117307932921825928971026432_by_1",
+ "typeString": "int_const 4253...(30 digits omitted)...6432"
+ },
+ "value": "0x020000000000000000000000000000000"
+ },
+ "src": "49916:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7186,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "49915:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 7187,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49960:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "49915:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7197,
+ "nodeType": "IfStatement",
+ "src": "49911:137:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7195,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7189,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49963:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7194,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7192,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7190,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "49969:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078313865626566396561633832306165383638326239373933616336643165373738",
+ "id": 7191,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "49975:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_530024347646835984032474664511850276728_by_1",
+ "typeString": "int_const 5300...(31 digits omitted)...6728"
+ },
+ "value": "0x18ebef9eac820ae8682b9793ac6d1e778"
+ },
+ "src": "49969:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078313336386232666336663936303966653761636562343661613631396261656434",
+ "id": 7193,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50013:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_412783376994266390547521411024565284564_by_1",
+ "typeString": "int_const 4127...(31 digits omitted)...4564"
+ },
+ "value": "0x1368b2fc6f9609fe7aceb46aa619baed4"
+ },
+ "src": "49969:79:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "49963:85:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7196,
+ "nodeType": "ExpressionStatement",
+ "src": "49963:85:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7203,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7200,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7198,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6869,
+ "src": "50088:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303430303030303030303030303030303030303030303030303030303030303030",
+ "id": 7199,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50092:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_85070591730234615865843651857942052864_by_1",
+ "typeString": "int_const 8507...(30 digits omitted)...2864"
+ },
+ "value": "0x040000000000000000000000000000000"
+ },
+ "src": "50088:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7201,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "50087:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 7202,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50132:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "50087:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7212,
+ "nodeType": "IfStatement",
+ "src": "50083:137:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7210,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7204,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50135:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7209,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7207,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7205,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50141:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078313336386232666336663936303966653761636562343661613631396261656435",
+ "id": 7206,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50147:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_412783376994266390547521411024565284565_by_1",
+ "typeString": "int_const 4127...(31 digits omitted)...4565"
+ },
+ "value": "0x1368b2fc6f9609fe7aceb46aa619baed5"
+ },
+ "src": "50141:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078306263356162316231363737396265333537356264386630353230613966323166",
+ "id": 7208,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50185:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_250365773966741064234501452596301656607_by_1",
+ "typeString": "int_const 2503...(31 digits omitted)...6607"
+ },
+ "value": "0x0bc5ab1b16779be3575bd8f0520a9f21f"
+ },
+ "src": "50141:79:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "50135:85:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7211,
+ "nodeType": "ExpressionStatement",
+ "src": "50135:85:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7218,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7215,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7213,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6869,
+ "src": "50260:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303830303030303030303030303030303030303030303030303030303030303030",
+ "id": 7214,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50264:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_170141183460469231731687303715884105728_by_1",
+ "typeString": "int_const 1701...(31 digits omitted)...5728"
+ },
+ "value": "0x080000000000000000000000000000000"
+ },
+ "src": "50260:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7216,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "50259:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 7217,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50304:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "50259:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7227,
+ "nodeType": "IfStatement",
+ "src": "50255:137:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7225,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7219,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50307:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7224,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7222,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7220,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50313:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078306263356162316231363737396265333537356264386630353230613966323165",
+ "id": 7221,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50319:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_250365773966741064234501452596301656606_by_1",
+ "typeString": "int_const 2503...(31 digits omitted)...6606"
+ },
+ "value": "0x0bc5ab1b16779be3575bd8f0520a9f21e"
+ },
+ "src": "50313:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303435346161613865666530373265376636646462616238346234306135356339",
+ "id": 7223,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50357:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_92104421015340344839251721785254237641_by_1",
+ "typeString": "int_const 9210...(30 digits omitted)...7641"
+ },
+ "value": "0x0454aaa8efe072e7f6ddbab84b40a55c9"
+ },
+ "src": "50313:79:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "50307:85:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7226,
+ "nodeType": "ExpressionStatement",
+ "src": "50307:85:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7233,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7230,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7228,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6869,
+ "src": "50432:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078313030303030303030303030303030303030303030303030303030303030303030",
+ "id": 7229,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50436:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_340282366920938463463374607431768211456_by_1",
+ "typeString": "int_const 3402...(31 digits omitted)...1456"
+ },
+ "value": "0x100000000000000000000000000000000"
+ },
+ "src": "50432:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7231,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "50431:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 7232,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50476:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "50431:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7242,
+ "nodeType": "IfStatement",
+ "src": "50427:137:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7240,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7234,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50479:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7239,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7237,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7235,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50485:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303435346161613865666530373265376636646462616238346234306135356335",
+ "id": 7236,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50491:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_92104421015340344839251721785254237637_by_1",
+ "typeString": "int_const 9210...(30 digits omitted)...7637"
+ },
+ "value": "0x0454aaa8efe072e7f6ddbab84b40a55c5"
+ },
+ "src": "50485:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303039363061616463313039653761336266343537383039393631353731316561",
+ "id": 7238,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50529:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_12464977905455307901915658421775307242_by_1",
+ "typeString": "int_const 1246...(30 digits omitted)...7242"
+ },
+ "value": "0x00960aadc109e7a3bf4578099615711ea"
+ },
+ "src": "50485:79:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "50479:85:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7241,
+ "nodeType": "ExpressionStatement",
+ "src": "50479:85:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7248,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7245,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7243,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6869,
+ "src": "50604:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078323030303030303030303030303030303030303030303030303030303030303030",
+ "id": 7244,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50608:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_680564733841876926926749214863536422912_by_1",
+ "typeString": "int_const 6805...(31 digits omitted)...2912"
+ },
+ "value": "0x200000000000000000000000000000000"
+ },
+ "src": "50604:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7246,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "50603:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 7247,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50648:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "50603:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7257,
+ "nodeType": "IfStatement",
+ "src": "50599:137:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7255,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7249,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50651:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7254,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7252,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7250,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50657:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303039363061616463313039653761336266343537383039393631353731316437",
+ "id": 7251,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50663:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_12464977905455307901915658421775307223_by_1",
+ "typeString": "int_const 1246...(30 digits omitted)...7223"
+ },
+ "value": "0x00960aadc109e7a3bf4578099615711d7"
+ },
+ "src": "50657:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030326266383432303832303466353937376639613863663031666463653364",
+ "id": 7253,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50701:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_228304034072369565894155946646425149_by_1",
+ "typeString": "int_const 2283...(28 digits omitted)...5149"
+ },
+ "value": "0x0002bf84208204f5977f9a8cf01fdce3d"
+ },
+ "src": "50657:79:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "50651:85:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7256,
+ "nodeType": "ExpressionStatement",
+ "src": "50651:85:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7263,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7260,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7258,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6869,
+ "src": "50776:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078343030303030303030303030303030303030303030303030303030303030303030",
+ "id": 7259,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50780:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1361129467683753853853498429727072845824_by_1",
+ "typeString": "int_const 1361...(32 digits omitted)...5824"
+ },
+ "value": "0x400000000000000000000000000000000"
+ },
+ "src": "50776:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7261,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "50775:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 7262,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50820:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "50775:46:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7272,
+ "nodeType": "IfStatement",
+ "src": "50771:137:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7270,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7264,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50823:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7269,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7267,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7265,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50829:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030326266383432303832303466353937376639613863663031666463333037",
+ "id": 7266,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50835:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_228304034072369565894155946646422279_by_1",
+ "typeString": "int_const 2283...(28 digits omitted)...2279"
+ },
+ "value": "0x0002bf84208204f5977f9a8cf01fdc307"
+ },
+ "src": "50829:41:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030336336616237373564643062393562346362656537653635643131",
+ "id": 7268,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "50873:35:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_76587471230661696290698490699025_by_1",
+ "typeString": "int_const 76587471230661696290698490699025"
+ },
+ "value": "0x0000003c6ab775dd0b95b4cbee7e65d11"
+ },
+ "src": "50829:79:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "50823:85:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7271,
+ "nodeType": "ExpressionStatement",
+ "src": "50823:85:7"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7273,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6875,
+ "src": "50952:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 6873,
+ "id": 7274,
+ "nodeType": "Return",
+ "src": "50945:10:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 6867,
+ "nodeType": "StructuredDocumentation",
+ "src": "47058:683:7",
+ "text": " @dev computes e ^ (x / FIXED_1) * FIXED_1\n input range: 0 <= x <= OPT_EXP_MAX_VAL - 1\n auto-generated via 'PrintFunctionOptimalExp.py'\n Detailed description:\n - Rewrite the input as a sum of binary exponents and a single residual r, as small as possible\n - The exponentiation of each binary exponent is given (pre-calculated)\n - The exponentiation of r is calculated via Taylor series for e^x, where x = r\n - The exponentiation of the input is calculated by multiplying the intermediate results above\n - For example: e^5.521692859 = e^(4 + 1 + 0.5 + 0.021692859) = e^4 * e^1 * e^0.5 * e^0.021692859"
+ },
+ "id": 7276,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "optimalExp",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 6870,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 6869,
+ "mutability": "mutable",
+ "name": "x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7276,
+ "src": "47767:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6868,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "47767:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "47766:11:7"
+ },
+ "returnParameters": {
+ "id": 6873,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 6872,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7276,
+ "src": "47801:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 6871,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "47801:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "47800:9:7"
+ },
+ "scope": 8977,
+ "src": "47747:3216:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 7312,
+ "nodeType": "Block",
+ "src": "51116:264:7",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7286,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7284,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7279,
+ "src": "51131:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7285,
+ "name": "LAMBERT_CONV_RADIUS",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3607,
+ "src": "51137:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "51131:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7291,
+ "nodeType": "IfStatement",
+ "src": "51127:66:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 7288,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7279,
+ "src": "51190:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 7287,
+ "name": "lambertPos1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7842,
+ "src": "51178:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 7289,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "51178:15:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7283,
+ "id": 7290,
+ "nodeType": "Return",
+ "src": "51171:22:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7294,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7292,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7279,
+ "src": "51208:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7293,
+ "name": "LAMBERT_POS2_MAXVAL",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3613,
+ "src": "51214:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "51208:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7299,
+ "nodeType": "IfStatement",
+ "src": "51204:66:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 7296,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7279,
+ "src": "51267:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 7295,
+ "name": "lambertPos2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7911,
+ "src": "51255:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) view returns (uint256)"
+ }
+ },
+ "id": 7297,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "51255:15:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7283,
+ "id": 7298,
+ "nodeType": "Return",
+ "src": "51248:22:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7302,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7300,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7279,
+ "src": "51285:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7301,
+ "name": "LAMBERT_POS3_MAXVAL",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3616,
+ "src": "51291:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "51285:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7307,
+ "nodeType": "IfStatement",
+ "src": "51281:66:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 7304,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7279,
+ "src": "51344:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 7303,
+ "name": "lambertPos3",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7961,
+ "src": "51332:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 7305,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "51332:15:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7283,
+ "id": 7306,
+ "nodeType": "Return",
+ "src": "51325:22:7"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "66616c7365",
+ "id": 7309,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "51366:5:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "false"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ ],
+ "id": 7308,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "51358:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$returns$__$",
+ "typeString": "function (bool) pure"
+ }
+ },
+ "id": 7310,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "51358:14:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 7311,
+ "nodeType": "ExpressionStatement",
+ "src": "51358:14:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 7277,
+ "nodeType": "StructuredDocumentation",
+ "src": "50971:75:7",
+ "text": " @dev computes W(x / FIXED_1) / (x / FIXED_1) * FIXED_1"
+ },
+ "id": 7313,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "lowerStake",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 7280,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7279,
+ "mutability": "mutable",
+ "name": "_x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7313,
+ "src": "51072:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7278,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "51072:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "51071:12:7"
+ },
+ "returnParameters": {
+ "id": 7283,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7282,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7313,
+ "src": "51107:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7281,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "51107:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "51106:9:7"
+ },
+ "scope": 8977,
+ "src": "51052:328:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 7335,
+ "nodeType": "Block",
+ "src": "51536:125:7",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7323,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7321,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7316,
+ "src": "51551:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7322,
+ "name": "LAMBERT_CONV_RADIUS",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3607,
+ "src": "51557:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "51551:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 7328,
+ "nodeType": "IfStatement",
+ "src": "51547:66:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 7325,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7316,
+ "src": "51610:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 7324,
+ "name": "lambertNeg1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8466,
+ "src": "51598:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 7326,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "51598:15:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7320,
+ "id": 7327,
+ "nodeType": "Return",
+ "src": "51591:22:7"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7333,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7331,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7329,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "51631:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7330,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "51641:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "51631:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7332,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7316,
+ "src": "51651:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "51631:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7320,
+ "id": 7334,
+ "nodeType": "Return",
+ "src": "51624:29:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 7314,
+ "nodeType": "StructuredDocumentation",
+ "src": "51388:77:7",
+ "text": " @dev computes W(-x / FIXED_1) / (-x / FIXED_1) * FIXED_1"
+ },
+ "id": 7336,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "higherStake",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 7317,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7316,
+ "mutability": "mutable",
+ "name": "_x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7336,
+ "src": "51492:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7315,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "51492:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "51491:12:7"
+ },
+ "returnParameters": {
+ "id": 7320,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7319,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7336,
+ "src": "51527:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7318,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "51527:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "51526:9:7"
+ },
+ "scope": 8977,
+ "src": "51471:190:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 7841,
+ "nodeType": "Block",
+ "src": "51921:4576:7",
+ "statements": [
+ {
+ "assignments": [
+ 7345
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7345,
+ "mutability": "mutable",
+ "name": "xi",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7841,
+ "src": "51932:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7344,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "51932:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7347,
+ "initialValue": {
+ "argumentTypes": null,
+ "id": 7346,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "51945:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "51932:15:7"
+ },
+ {
+ "assignments": [
+ 7349
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7349,
+ "mutability": "mutable",
+ "name": "res",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7841,
+ "src": "51958:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7348,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "51958:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7356,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7355,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7352,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7350,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "51973:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7351,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "51983:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "51973:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7353,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "51972:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30786465316263346431396566636163383234343564613735623030303030303030",
+ "id": 7354,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "51989:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_295232799039604140847618609643520000000_by_1",
+ "typeString": "int_const 2952...(31 digits omitted)...0000"
+ },
+ "value": "0xde1bc4d19efcac82445da75b00000000"
+ },
+ "src": "51972:51:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "51958:65:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7364,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7357,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52103:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7363,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7360,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7358,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52109:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7359,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "52114:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52109:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7361,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "52108:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7362,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "52120:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52108:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52103:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7365,
+ "nodeType": "ExpressionStatement",
+ "src": "52103:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7370,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7366,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "52129:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7369,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7367,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52136:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303030313464323961373361366537623032633336363863376230383830303030303030",
+ "id": 7368,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "52141:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_442849198559406211271427914465280000000_by_1",
+ "typeString": "int_const 4428...(31 digits omitted)...0000"
+ },
+ "value": "0x00000000014d29a73a6e7b02c3668c7b0880000000"
+ },
+ "src": "52136:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52129:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7371,
+ "nodeType": "ExpressionStatement",
+ "src": "52129:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7379,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7372,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52238:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7378,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7375,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7373,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52244:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7374,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "52249:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52244:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7376,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "52243:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7377,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "52255:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52243:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52238:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7380,
+ "nodeType": "ExpressionStatement",
+ "src": "52238:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7385,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7381,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "52264:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7384,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7382,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52271:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303030323530346130636439613766373231356236306639626534383030303030303030",
+ "id": 7383,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "52276:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_787287464105611042260316292382720000000_by_1",
+ "typeString": "int_const 7872...(31 digits omitted)...0000"
+ },
+ "value": "0x0000000002504a0cd9a7f7215b60f9be4800000000"
+ },
+ "src": "52271:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52264:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7386,
+ "nodeType": "ExpressionStatement",
+ "src": "52264:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7394,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7387,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52373:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7393,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7390,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7388,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52379:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7389,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "52384:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52379:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7391,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "52378:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7392,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "52390:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52378:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52373:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7395,
+ "nodeType": "ExpressionStatement",
+ "src": "52373:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7400,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7396,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "52399:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7399,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7397,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52406:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303030343834643061313139316330656164323637393637633761346130303030303030",
+ "id": 7398,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "52411:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1537670828331271566914680258560000000000_by_1",
+ "typeString": "int_const 1537...(32 digits omitted)...0000"
+ },
+ "value": "0x000000000484d0a1191c0ead267967c7a4a0000000"
+ },
+ "src": "52406:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52399:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7401,
+ "nodeType": "ExpressionStatement",
+ "src": "52399:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7409,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7402,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52508:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7408,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7405,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7403,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52514:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7404,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "52519:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52514:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7406,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "52513:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7407,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "52525:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52513:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52508:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7410,
+ "nodeType": "ExpressionStatement",
+ "src": "52508:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7415,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7411,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "52534:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7414,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7412,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52541:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303030393565633538306437653834323761346261663236613930613030303030303030",
+ "id": 7413,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "52546:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3188514229627724721154280984150016000000_by_1",
+ "typeString": "int_const 3188...(32 digits omitted)...0000"
+ },
+ "value": "0x00000000095ec580d7e8427a4baf26a90a00000000"
+ },
+ "src": "52541:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52534:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7416,
+ "nodeType": "ExpressionStatement",
+ "src": "52534:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7424,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7417,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52643:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7423,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7420,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7418,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52649:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7419,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "52654:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52649:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7421,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "52648:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7422,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "52660:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52648:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52643:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7425,
+ "nodeType": "ExpressionStatement",
+ "src": "52643:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7430,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7426,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "52669:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7429,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7427,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52676:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303031343430623062653136313561343764626136653562336231663130303030303030",
+ "id": 7428,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "52681:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6891635629803648326702674961498112000000_by_1",
+ "typeString": "int_const 6891...(32 digits omitted)...0000"
+ },
+ "value": "0x000000001440b0be1615a47dba6e5b3b1f10000000"
+ },
+ "src": "52676:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52669:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7431,
+ "nodeType": "ExpressionStatement",
+ "src": "52669:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7439,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7432,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52778:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7438,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7435,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7433,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52784:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7434,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "52789:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52784:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7436,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "52783:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7437,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "52795:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52783:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52778:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7440,
+ "nodeType": "ExpressionStatement",
+ "src": "52778:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7445,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7441,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "52804:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7444,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7442,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52811:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303032643230373630316634366139396234313132343138343030303030303030303030",
+ "id": 7443,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "52816:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_15355854537983727757610740636188672000000_by_1",
+ "typeString": "int_const 1535...(33 digits omitted)...0000"
+ },
+ "value": "0x000000002d207601f46a99b4112418400000000000"
+ },
+ "src": "52811:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52804:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7446,
+ "nodeType": "ExpressionStatement",
+ "src": "52804:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7454,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7447,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52913:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7453,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7450,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7448,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52919:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7449,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "52924:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52919:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7451,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "52918:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7452,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "52930:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52918:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52913:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7455,
+ "nodeType": "ExpressionStatement",
+ "src": "52913:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7460,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7456,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "52939:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7459,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7457,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "52946:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303036366562616163346333376336323264643832383861376562316232303030303030",
+ "id": 7458,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "52951:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_35022056686251398262544482483830784000000_by_1",
+ "typeString": "int_const 3502...(33 digits omitted)...0000"
+ },
+ "value": "0x0000000066ebaac4c37c622dd8288a7eb1b2000000"
+ },
+ "src": "52946:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "52939:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7461,
+ "nodeType": "ExpressionStatement",
+ "src": "52939:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7469,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7462,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53048:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7468,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7465,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7463,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53054:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7464,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "53059:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53054:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7466,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "53053:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7467,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "53065:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53053:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53048:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7470,
+ "nodeType": "ExpressionStatement",
+ "src": "53048:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7475,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7471,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "53074:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7474,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7472,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53081:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303065663137323430313335663764626434336131626131306366323030303030303030",
+ "id": 7473,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "53086:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_81358244885252463857919590400000000000000_by_1",
+ "typeString": "int_const 8135...(33 digits omitted)...0000"
+ },
+ "value": "0x00000000ef17240135f7dbd43a1ba10cf200000000"
+ },
+ "src": "53081:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53074:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7476,
+ "nodeType": "ExpressionStatement",
+ "src": "53074:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7484,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7477,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53183:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7483,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7480,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7478,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53189:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7479,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "53194:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53189:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7481,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "53188:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7482,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "53200:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53188:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53183:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7485,
+ "nodeType": "ExpressionStatement",
+ "src": "53183:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7490,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7486,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "53209:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7489,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7487,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53216:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303233336333336336373661356562323431363039346138376233363537303030303030",
+ "id": 7488,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "53221:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_191838485670993607105842450247345766400000_by_1",
+ "typeString": "int_const 1918...(34 digits omitted)...0000"
+ },
+ "value": "0x0000000233c33c676a5eb2416094a87b3657000000"
+ },
+ "src": "53216:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53209:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7491,
+ "nodeType": "ExpressionStatement",
+ "src": "53209:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7499,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7492,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53318:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7498,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7495,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7493,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53324:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7494,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "53329:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53324:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7496,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "53323:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7497,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "53335:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53323:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53318:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7500,
+ "nodeType": "ExpressionStatement",
+ "src": "53318:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7505,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7501,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "53344:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7504,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7502,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53351:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303534316364653438626330323534626564343961396638373030303030303030303030",
+ "id": 7503,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "53356:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_457953461925960171898563951427426713600000_by_1",
+ "typeString": "int_const 4579...(34 digits omitted)...0000"
+ },
+ "value": "0x0000000541cde48bc0254bed49a9f8700000000000"
+ },
+ "src": "53351:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53344:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7506,
+ "nodeType": "ExpressionStatement",
+ "src": "53344:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7514,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7507,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53453:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7513,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7510,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7508,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53459:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7509,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "53464:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53459:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7511,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "53458:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7512,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "53470:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53458:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53453:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7515,
+ "nodeType": "ExpressionStatement",
+ "src": "53453:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7520,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7516,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "53479:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7519,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7517,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53486:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030306361653166616432636464346434636238643733616263613064313961343030303030",
+ "id": 7518,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "53491:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1104598668270551480892683896320648806400000_by_1",
+ "typeString": "int_const 1104...(35 digits omitted)...0000"
+ },
+ "value": "0x0000000cae1fad2cdd4d4cb8d73abca0d19a400000"
+ },
+ "src": "53486:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53479:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7521,
+ "nodeType": "ExpressionStatement",
+ "src": "53479:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7529,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7522,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53588:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7528,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7525,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7523,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53594:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7524,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "53599:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53594:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7526,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "53593:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7527,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "53605:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53593:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53588:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7530,
+ "nodeType": "ExpressionStatement",
+ "src": "53588:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7535,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7531,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "53614:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7534,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7532,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53621:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030316564623261613266373630643135633431636565646261393536343030303030303030",
+ "id": 7533,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "53626:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2687947090053832841608264823563773542400000_by_1",
+ "typeString": "int_const 2687...(35 digits omitted)...0000"
+ },
+ "value": "0x0000001edb2aa2f760d15c41ceedba956400000000"
+ },
+ "src": "53621:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53614:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7536,
+ "nodeType": "ExpressionStatement",
+ "src": "53614:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7544,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7537,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53723:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7543,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7540,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7538,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53729:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7539,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "53734:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53729:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7541,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "53728:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7542,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "53740:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53728:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53723:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7545,
+ "nodeType": "ExpressionStatement",
+ "src": "53723:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7550,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7546,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "53749:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7549,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7547,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53756:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030346261386432306432646162643338366339353239363539383431613265323030303030",
+ "id": 7548,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "53761:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6590868088830032065882824000000000000000000_by_1",
+ "typeString": "int_const 6590...(35 digits omitted)...0000"
+ },
+ "value": "0x0000004ba8d20d2dabd386c9529659841a2e200000"
+ },
+ "src": "53756:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53749:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7551,
+ "nodeType": "ExpressionStatement",
+ "src": "53749:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7559,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7552,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53858:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7558,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7555,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7553,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53864:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7554,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "53869:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53864:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7556,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "53863:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7557,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "53875:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53863:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53858:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7560,
+ "nodeType": "ExpressionStatement",
+ "src": "53858:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7565,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7561,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "53884:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7564,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7562,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53891:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030626163303835343662383637636461613230303030303030303030303030303030303030",
+ "id": 7563,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "53896:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_16268396552280633070412438458028041175040000_by_1",
+ "typeString": "int_const 1626...(36 digits omitted)...0000"
+ },
+ "value": "0x000000bac08546b867cdaa20000000000000000000"
+ },
+ "src": "53891:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53884:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7566,
+ "nodeType": "ExpressionStatement",
+ "src": "53884:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7574,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7567,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53993:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7573,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7570,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7568,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "53999:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7569,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "54004:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53999:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7571,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "53998:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7572,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "54010:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53998:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "53993:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7575,
+ "nodeType": "ExpressionStatement",
+ "src": "53993:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7580,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7576,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "54019:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7579,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7577,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54026:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303031636661386537306330333632356239646237366338656266356262663234383230303030",
+ "id": 7578,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "54031:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_40390462938090940419774080664538139934720000_by_1",
+ "typeString": "int_const 4039...(36 digits omitted)...0000"
+ },
+ "value": "0x000001cfa8e70c03625b9db76c8ebf5bbf24820000"
+ },
+ "src": "54026:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54019:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7581,
+ "nodeType": "ExpressionStatement",
+ "src": "54019:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7589,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7582,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54128:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7588,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7585,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7583,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54134:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7584,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "54139:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54134:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7586,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "54133:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7587,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "54145:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54133:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54128:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7590,
+ "nodeType": "ExpressionStatement",
+ "src": "54128:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7595,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7591,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "54154:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7594,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7592,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54161:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303034383531643939663832303630646632363566333330396232366638323030303030303030",
+ "id": 7593,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "54166:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_100798987671917000666814256179934522245120000_by_1",
+ "typeString": "int_const 1007...(37 digits omitted)...0000"
+ },
+ "value": "0x000004851d99f82060df265f3309b26f8200000000"
+ },
+ "src": "54161:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54154:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7596,
+ "nodeType": "ExpressionStatement",
+ "src": "54154:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7604,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7597,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54263:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7603,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7600,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7598,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54269:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7599,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "54274:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54269:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7601,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "54268:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7602,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "54280:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54268:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54263:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7605,
+ "nodeType": "ExpressionStatement",
+ "src": "54263:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7610,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7606,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "54289:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7609,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7607,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54296:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303062353530643139623132396432373063343466366635356630323737323363626230303030",
+ "id": 7608,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "54301:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_252717199309391137912965664538441463029760000_by_1",
+ "typeString": "int_const 2527...(37 digits omitted)...0000"
+ },
+ "value": "0x00000b550d19b129d270c44f6f55f027723cbb0000"
+ },
+ "src": "54296:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54289:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7611,
+ "nodeType": "ExpressionStatement",
+ "src": "54289:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7619,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7612,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54398:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7618,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7615,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7613,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54404:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7614,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "54409:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54404:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7616,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "54403:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7617,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "54415:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54403:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54398:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7620,
+ "nodeType": "ExpressionStatement",
+ "src": "54398:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7625,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7621,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "54424:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7624,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7622,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54431:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303163383737646164633736316463323732646562363564346230303030303030303030303030",
+ "id": 7623,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "54436:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_636223790447205380259840000000000000000000000_by_1",
+ "typeString": "int_const 6362...(37 digits omitted)...0000"
+ },
+ "value": "0x00001c877dadc761dc272deb65d4b0000000000000"
+ },
+ "src": "54431:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54424:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7626,
+ "nodeType": "ExpressionStatement",
+ "src": "54424:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7634,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7627,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54533:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7633,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7630,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7628,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54539:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7629,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "54544:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54539:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7631,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "54538:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7632,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "54550:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54538:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54533:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7635,
+ "nodeType": "ExpressionStatement",
+ "src": "54533:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7640,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7636,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "54559:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7639,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7637,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54566:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303438313738656365393734373966333361373766326164323261383162363434303663303030",
+ "id": 7638,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "54571:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1607705831573194746802610334450509017233408000_by_1",
+ "typeString": "int_const 1607...(38 digits omitted)...8000"
+ },
+ "value": "0x000048178ece97479f33a77f2ad22a81b64406c000"
+ },
+ "src": "54566:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54559:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7641,
+ "nodeType": "ExpressionStatement",
+ "src": "54559:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7649,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7642,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54668:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7648,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7645,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7643,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54674:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7644,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "54679:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54674:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7646,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "54673:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7647,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "54685:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54673:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54668:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7650,
+ "nodeType": "ExpressionStatement",
+ "src": "54668:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7655,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7651,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "54694:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7654,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7652,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54701:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030306236636138323638623964383130666564663636393565663266386136633030303030303030",
+ "id": 7653,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "54706:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4076376683803157531046819273912505658769408000_by_1",
+ "typeString": "int_const 4076...(38 digits omitted)...8000"
+ },
+ "value": "0x0000b6ca8268b9d810fedf6695ef2f8a6c00000000"
+ },
+ "src": "54701:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54694:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7656,
+ "nodeType": "ExpressionStatement",
+ "src": "54694:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7664,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7657,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54803:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7663,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7660,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7658,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54809:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7659,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "54814:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54809:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7661,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "54808:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7662,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "54820:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54808:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54803:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7665,
+ "nodeType": "ExpressionStatement",
+ "src": "54803:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7670,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7666,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "54829:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7669,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7667,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54836:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030316430653736363331613562303564303037623863623732613763376631316563333665303030",
+ "id": 7668,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "54841:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_10367703484962349537949059901011799777283072000_by_1",
+ "typeString": "int_const 1036...(39 digits omitted)...2000"
+ },
+ "value": "0x0001d0e76631a5b05d007b8cb72a7c7f11ec36e000"
+ },
+ "src": "54836:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54829:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7671,
+ "nodeType": "ExpressionStatement",
+ "src": "54829:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7679,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7672,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54938:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7678,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7675,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7673,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54944:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7674,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "54949:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54944:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7676,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "54943:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7677,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "54955:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54943:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54938:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7680,
+ "nodeType": "ExpressionStatement",
+ "src": "54938:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7685,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7681,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "54964:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7684,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7682,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "54971:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030346131633337626439663835666439633663373830303030303030303030303030303030303030",
+ "id": 7683,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "54976:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_26443412100478721735433130630260686447443968000_by_1",
+ "typeString": "int_const 2644...(39 digits omitted)...8000"
+ },
+ "value": "0x0004a1c37bd9f85fd9c6c780000000000000000000"
+ },
+ "src": "54971:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "54964:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7686,
+ "nodeType": "ExpressionStatement",
+ "src": "54964:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7694,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7687,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55073:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7693,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7690,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7688,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55079:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7689,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "55084:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55079:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7691,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "55078:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7692,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "55090:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55078:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55073:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7695,
+ "nodeType": "ExpressionStatement",
+ "src": "55073:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7700,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7696,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "55099:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7699,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7697,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55106:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030626438333639663162373032626634393165326562666365653038323530333133623635343030",
+ "id": 7698,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "55111:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_67620617646753089502453804016113281250000000000_by_1",
+ "typeString": "int_const 6762...(39 digits omitted)...0000"
+ },
+ "value": "0x000bd8369f1b702bf491e2ebfcee08250313b65400"
+ },
+ "src": "55106:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55099:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7701,
+ "nodeType": "ExpressionStatement",
+ "src": "55099:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7709,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7702,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55208:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7708,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7705,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7703,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55214:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7704,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "55219:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55214:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7706,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "55213:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7707,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "55225:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55213:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55208:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7710,
+ "nodeType": "ExpressionStatement",
+ "src": "55208:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7715,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7711,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "55234:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7714,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7712,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55241:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303031653563376333326139663663373061623263623539643932323537363464343030303030303030",
+ "id": 7713,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "55246:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_173332210846474760735500226875327576716638945280_by_1",
+ "typeString": "int_const 1733...(40 digits omitted)...5280"
+ },
+ "value": "0x001e5c7c32a9f6c70ab2cb59d9225764d400000000"
+ },
+ "src": "55241:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55234:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7716,
+ "nodeType": "ExpressionStatement",
+ "src": "55234:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7724,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7717,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55343:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7723,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7720,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7718,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55349:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7719,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "55354:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55349:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7721,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "55348:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7722,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "55360:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55348:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55343:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7725,
+ "nodeType": "ExpressionStatement",
+ "src": "55343:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7730,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7726,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "55369:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7729,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7727,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55376:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303034646666353832306531363565393130663935313230613730386537343234393632323165363030",
+ "id": 7728,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "55381:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_445286656448864136819345605176268818347976680960_by_1",
+ "typeString": "int_const 4452...(40 digits omitted)...0960"
+ },
+ "value": "0x004dff5820e165e910f95120a708e742496221e600"
+ },
+ "src": "55376:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55369:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7731,
+ "nodeType": "ExpressionStatement",
+ "src": "55369:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7739,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7732,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55478:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7738,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7735,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7733,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55484:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7734,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "55489:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55484:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7736,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "55483:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7737,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "55495:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55483:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55478:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7740,
+ "nodeType": "ExpressionStatement",
+ "src": "55478:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7745,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7741,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "55504:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7744,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7742,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55511:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303063386338663636646231666365643337386565353065353336303030303030303030303030303030",
+ "id": 7743,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "55516:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1146279770154177862273033179056478989553563074560_by_1",
+ "typeString": "int_const 1146...(41 digits omitted)...4560"
+ },
+ "value": "0x00c8c8f66db1fced378ee50e536000000000000000"
+ },
+ "src": "55511:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55504:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7746,
+ "nodeType": "ExpressionStatement",
+ "src": "55504:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7754,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7747,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55613:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7753,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7750,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7748,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55619:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7749,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "55624:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55619:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7751,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "55618:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7752,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "55630:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55618:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55613:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7755,
+ "nodeType": "ExpressionStatement",
+ "src": "55613:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7760,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7756,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "55639:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7759,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7757,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55646:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303230356462386466666666343562666132393338663132386635393964626631366562313164383830",
+ "id": 7758,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "55651:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2956444461658038477759873400213214992927382689920_by_1",
+ "typeString": "int_const 2956...(41 digits omitted)...9920"
+ },
+ "value": "0x0205db8dffff45bfa2938f128f599dbf16eb11d880"
+ },
+ "src": "55646:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55639:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7761,
+ "nodeType": "ExpressionStatement",
+ "src": "55639:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7769,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7762,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55748:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7768,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7765,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7763,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55754:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7764,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "55759:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55754:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7766,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "55753:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7767,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "55765:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55753:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55748:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7770,
+ "nodeType": "ExpressionStatement",
+ "src": "55748:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7775,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7771,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "55774:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7774,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7772,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55781:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303533613034346562643938343335313439336531373836616633386433396130383030303030303030",
+ "id": 7773,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "55786:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_7638725713617153619200000000000000000000000000000_by_1",
+ "typeString": "int_const 7638...(41 digits omitted)...0000"
+ },
+ "value": "0x053a044ebd984351493e1786af38d39a0800000000"
+ },
+ "src": "55781:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55774:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7776,
+ "nodeType": "ExpressionStatement",
+ "src": "55774:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7784,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7777,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55883:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7783,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7780,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7778,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55889:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7779,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "55894:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55889:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7781,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "55888:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7782,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "55900:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55888:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55883:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7785,
+ "nodeType": "ExpressionStatement",
+ "src": "55883:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7790,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7786,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "55909:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7789,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7787,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "55916:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078306438366461653261346363306634373633336135343434373937333538363962343837623539633430",
+ "id": 7788,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "55921:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_19769407354499582705095371848882117322613875645504_by_1",
+ "typeString": "int_const 1976...(42 digits omitted)...5504"
+ },
+ "value": "0x0d86dae2a4cc0f47633a544479735869b487b59c40"
+ },
+ "src": "55916:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "55909:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7791,
+ "nodeType": "ExpressionStatement",
+ "src": "55909:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7799,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7792,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56018:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7798,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7795,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7793,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56024:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7794,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "56029:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56024:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7796,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "56023:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7797,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "56035:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56023:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56018:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7800,
+ "nodeType": "ExpressionStatement",
+ "src": "56018:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7805,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7801,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "56044:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7804,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7802,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56051:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078323331303030303030303030303030303030303030303030303030303030303030303030303030303030",
+ "id": 7803,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "56056:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_51243901158914783569516699447114673376686134788096_by_1",
+ "typeString": "int_const 5124...(42 digits omitted)...8096"
+ },
+ "value": "0x231000000000000000000000000000000000000000"
+ },
+ "src": "56051:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56044:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7806,
+ "nodeType": "ExpressionStatement",
+ "src": "56044:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7814,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7807,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56153:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7813,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7810,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7808,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56159:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7809,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "56164:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56159:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7811,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "56158:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7812,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "56170:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56158:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56153:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7815,
+ "nodeType": "ExpressionStatement",
+ "src": "56153:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7820,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7816,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "56179:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7819,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7817,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56186:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078356230343835613736663636343663323033396462313530376364643531623038363439363830383232",
+ "id": 7818,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "56191:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_133022465544965907471119545993290733585983764695074_by_1",
+ "typeString": "int_const 1330...(43 digits omitted)...5074"
+ },
+ "value": "0x5b0485a76f6646c2039db1507cdd51b08649680822"
+ },
+ "src": "56186:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56179:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7821,
+ "nodeType": "ExpressionStatement",
+ "src": "56179:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7829,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7822,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56288:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7828,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7825,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7823,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56294:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7824,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7339,
+ "src": "56299:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56294:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7826,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "56293:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7827,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "56305:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56293:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56288:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7830,
+ "nodeType": "ExpressionStatement",
+ "src": "56288:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7835,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7831,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "56314:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7834,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7832,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7345,
+ "src": "56321:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078656339383363343663343935343562633137656661366235623030353565323432323030303030303030",
+ "id": 7833,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "56326:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_345783497216724000335707367685598692782880644399104_by_1",
+ "typeString": "int_const 3457...(43 digits omitted)...9104"
+ },
+ "value": "0xec983c46c49545bc17efa6b5b0055e242200000000"
+ },
+ "src": "56321:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56314:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7836,
+ "nodeType": "ExpressionStatement",
+ "src": "56314:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7839,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7837,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7349,
+ "src": "56432:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30786465316263346431396566636163383234343564613735623030303030303030",
+ "id": 7838,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "56438:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_295232799039604140847618609643520000000_by_1",
+ "typeString": "int_const 2952...(31 digits omitted)...0000"
+ },
+ "value": "0xde1bc4d19efcac82445da75b00000000"
+ },
+ "src": "56432:40:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7343,
+ "id": 7840,
+ "nodeType": "Return",
+ "src": "56425:47:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 7337,
+ "nodeType": "StructuredDocumentation",
+ "src": "51669:181:7",
+ "text": " @dev computes W(x / FIXED_1) / (x / FIXED_1) * FIXED_1\n input range: 1 <= x <= 1 / e * FIXED_1\n auto-generated via 'PrintFunctionLambertPos1.py'"
+ },
+ "id": 7842,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "lambertPos1",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 7340,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7339,
+ "mutability": "mutable",
+ "name": "_x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7842,
+ "src": "51877:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7338,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "51877:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "51876:12:7"
+ },
+ "returnParameters": {
+ "id": 7343,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7342,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7842,
+ "src": "51912:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7341,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "51912:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "51911:9:7"
+ },
+ "scope": 8977,
+ "src": "51856:4641:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 7910,
+ "nodeType": "Block",
+ "src": "56725:350:7",
+ "statements": [
+ {
+ "assignments": [
+ 7851
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7851,
+ "mutability": "mutable",
+ "name": "x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7910,
+ "src": "56736:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7850,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "56736:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7857,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7856,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7854,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7852,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7845,
+ "src": "56748:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7853,
+ "name": "LAMBERT_CONV_RADIUS",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3607,
+ "src": "56753:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56748:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 7855,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "56775:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "56748:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "56736:40:7"
+ },
+ {
+ "assignments": [
+ 7859
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7859,
+ "mutability": "mutable",
+ "name": "i",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7910,
+ "src": "56787:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7858,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "56787:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7863,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7862,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7860,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7851,
+ "src": "56799:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7861,
+ "name": "LAMBERT_POS2_SAMPLE",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3610,
+ "src": "56803:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56799:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "56787:35:7"
+ },
+ {
+ "assignments": [
+ 7865
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7865,
+ "mutability": "mutable",
+ "name": "a",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7910,
+ "src": "56833:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7864,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "56833:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7869,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7868,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7866,
+ "name": "LAMBERT_POS2_SAMPLE",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3610,
+ "src": "56845:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7867,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7859,
+ "src": "56867:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56845:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "56833:35:7"
+ },
+ {
+ "assignments": [
+ 7871
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7871,
+ "mutability": "mutable",
+ "name": "b",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7910,
+ "src": "56879:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7870,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "56879:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7878,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7877,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7872,
+ "name": "LAMBERT_POS2_SAMPLE",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3610,
+ "src": "56891:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7875,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7873,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7859,
+ "src": "56914:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 7874,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "56918:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "56914:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7876,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "56913:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "56891:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "56879:41:7"
+ },
+ {
+ "assignments": [
+ 7880
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7880,
+ "mutability": "mutable",
+ "name": "c",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7910,
+ "src": "56931:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7879,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "56931:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7884,
+ "initialValue": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 7881,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "56943:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 7883,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 7882,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7859,
+ "src": "56956:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "56943:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "56931:27:7"
+ },
+ {
+ "assignments": [
+ 7886
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7886,
+ "mutability": "mutable",
+ "name": "d",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7910,
+ "src": "56969:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7885,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "56969:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7892,
+ "initialValue": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 7887,
+ "name": "lambertArray",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 4207,
+ "src": "56981:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_uint256_$128_storage",
+ "typeString": "uint256[128] storage ref"
+ }
+ },
+ "id": 7891,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7890,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7888,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7859,
+ "src": "56994:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 7889,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "56998:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "56994:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "56981:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "56969:31:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7908,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7905,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7898,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7893,
+ "name": "c",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7880,
+ "src": "57019:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7896,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7894,
+ "name": "b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7871,
+ "src": "57024:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7895,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7851,
+ "src": "57028:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57024:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7897,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "57023:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57019:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7904,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7899,
+ "name": "d",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7886,
+ "src": "57033:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7902,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7900,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7851,
+ "src": "57038:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7901,
+ "name": "a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7865,
+ "src": "57042:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57038:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7903,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "57037:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57033:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57019:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7906,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "57018:27:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7907,
+ "name": "LAMBERT_POS2_SAMPLE",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3610,
+ "src": "57048:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57018:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7849,
+ "id": 7909,
+ "nodeType": "Return",
+ "src": "57011:56:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 7843,
+ "nodeType": "StructuredDocumentation",
+ "src": "56505:149:7",
+ "text": " @dev computes W(x / FIXED_1) / (x / FIXED_1) * FIXED_1\n input range: LAMBERT_CONV_RADIUS + 1 <= x <= LAMBERT_POS2_MAXVAL"
+ },
+ "id": 7911,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "lambertPos2",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 7846,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7845,
+ "mutability": "mutable",
+ "name": "_x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7911,
+ "src": "56681:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7844,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "56681:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "56680:12:7"
+ },
+ "returnParameters": {
+ "id": 7849,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7848,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7911,
+ "src": "56716:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7847,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "56716:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "56715:9:7"
+ },
+ "scope": 8977,
+ "src": "56660:415:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 7960,
+ "nodeType": "Block",
+ "src": "57303:226:7",
+ "statements": [
+ {
+ "assignments": [
+ 7920
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7920,
+ "mutability": "mutable",
+ "name": "l1",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7960,
+ "src": "57314:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7919,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "57314:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7931,
+ "initialValue": {
+ "argumentTypes": null,
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7923,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7921,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7914,
+ "src": "57327:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7922,
+ "name": "OPT_LOG_MAX_VAL",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3601,
+ "src": "57332:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57327:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 7928,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7914,
+ "src": "57378:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 7927,
+ "name": "generalLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5906,
+ "src": "57367:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 7929,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "57367:14:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7930,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "Conditional",
+ "src": "57327:54:7",
+ "trueExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 7925,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7914,
+ "src": "57361:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 7924,
+ "name": "optimalLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6866,
+ "src": "57350:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 7926,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "57350:14:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "57314:67:7"
+ },
+ {
+ "assignments": [
+ 7933
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7933,
+ "mutability": "mutable",
+ "name": "l2",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7960,
+ "src": "57392:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7932,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "57392:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7944,
+ "initialValue": {
+ "argumentTypes": null,
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7936,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7934,
+ "name": "l1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7920,
+ "src": "57405:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7935,
+ "name": "OPT_LOG_MAX_VAL",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3601,
+ "src": "57410:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57405:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 7941,
+ "name": "l1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7920,
+ "src": "57456:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 7940,
+ "name": "generalLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5906,
+ "src": "57445:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 7942,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "57445:14:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7943,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "Conditional",
+ "src": "57405:54:7",
+ "trueExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 7938,
+ "name": "l1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7920,
+ "src": "57439:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 7937,
+ "name": "optimalLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6866,
+ "src": "57428:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 7939,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "57428:14:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "57392:67:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7958,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7956,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7953,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7947,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7945,
+ "name": "l1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7920,
+ "src": "57478:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7946,
+ "name": "l2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7933,
+ "src": "57483:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57478:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7952,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7950,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7948,
+ "name": "l2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7933,
+ "src": "57488:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7949,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "57493:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57488:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7951,
+ "name": "l1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7920,
+ "src": "57503:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57488:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57478:27:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7954,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "57477:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7955,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "57509:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57477:39:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7957,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7914,
+ "src": "57519:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57477:44:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7918,
+ "id": 7959,
+ "nodeType": "Return",
+ "src": "57470:51:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 7912,
+ "nodeType": "StructuredDocumentation",
+ "src": "57083:149:7",
+ "text": " @dev computes W(x / FIXED_1) / (x / FIXED_1) * FIXED_1\n input range: LAMBERT_POS2_MAXVAL + 1 <= x <= LAMBERT_POS3_MAXVAL"
+ },
+ "id": 7961,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "lambertPos3",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 7915,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7914,
+ "mutability": "mutable",
+ "name": "_x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7961,
+ "src": "57259:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7913,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "57259:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "57258:12:7"
+ },
+ "returnParameters": {
+ "id": 7918,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7917,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 7961,
+ "src": "57294:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7916,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "57294:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "57293:9:7"
+ },
+ "scope": 8977,
+ "src": "57238:291:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 8465,
+ "nodeType": "Block",
+ "src": "57791:4551:7",
+ "statements": [
+ {
+ "assignments": [
+ 7970
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7970,
+ "mutability": "mutable",
+ "name": "xi",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8465,
+ "src": "57802:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7969,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "57802:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7972,
+ "initialValue": {
+ "argumentTypes": null,
+ "id": 7971,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "57815:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "57802:15:7"
+ },
+ {
+ "assignments": [
+ 7974
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 7974,
+ "mutability": "mutable",
+ "name": "res",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8465,
+ "src": "57828:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7973,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "57828:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 7976,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 7975,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "57842:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "57828:15:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7984,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7977,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "57856:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7983,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7980,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7978,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "57862:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7979,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "57867:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57862:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7981,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "57861:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7982,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "57873:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57861:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57856:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7985,
+ "nodeType": "ExpressionStatement",
+ "src": "57856:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7990,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7986,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "57882:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7989,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7987,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "57889:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303030313464323961373361366537623032633336363863376230383830303030303030",
+ "id": 7988,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "57894:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_442849198559406211271427914465280000000_by_1",
+ "typeString": "int_const 4428...(31 digits omitted)...0000"
+ },
+ "value": "0x00000000014d29a73a6e7b02c3668c7b0880000000"
+ },
+ "src": "57889:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57882:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 7991,
+ "nodeType": "ExpressionStatement",
+ "src": "57882:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 7999,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 7992,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "57991:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7998,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 7995,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 7993,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "57997:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7994,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "58002:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57997:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 7996,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "57996:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 7997,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "58008:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57996:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "57991:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8000,
+ "nodeType": "ExpressionStatement",
+ "src": "57991:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8005,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8001,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "58017:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8004,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8002,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58024:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303030323530346130636439613766373231356236306639626534383030303030303030",
+ "id": 8003,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "58029:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_787287464105611042260316292382720000000_by_1",
+ "typeString": "int_const 7872...(31 digits omitted)...0000"
+ },
+ "value": "0x0000000002504a0cd9a7f7215b60f9be4800000000"
+ },
+ "src": "58024:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58017:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8006,
+ "nodeType": "ExpressionStatement",
+ "src": "58017:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8014,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8007,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58126:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8013,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8010,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8008,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58132:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8009,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "58137:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58132:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8011,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "58131:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8012,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "58143:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58131:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58126:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8015,
+ "nodeType": "ExpressionStatement",
+ "src": "58126:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8020,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8016,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "58152:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8019,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8017,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58159:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303030343834643061313139316330656164323637393637633761346130303030303030",
+ "id": 8018,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "58164:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1537670828331271566914680258560000000000_by_1",
+ "typeString": "int_const 1537...(32 digits omitted)...0000"
+ },
+ "value": "0x000000000484d0a1191c0ead267967c7a4a0000000"
+ },
+ "src": "58159:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58152:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8021,
+ "nodeType": "ExpressionStatement",
+ "src": "58152:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8029,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8022,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58261:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8028,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8025,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8023,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58267:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8024,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "58272:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58267:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8026,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "58266:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8027,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "58278:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58266:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58261:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8030,
+ "nodeType": "ExpressionStatement",
+ "src": "58261:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8035,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8031,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "58287:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8034,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8032,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58294:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303030393565633538306437653834323761346261663236613930613030303030303030",
+ "id": 8033,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "58299:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3188514229627724721154280984150016000000_by_1",
+ "typeString": "int_const 3188...(32 digits omitted)...0000"
+ },
+ "value": "0x00000000095ec580d7e8427a4baf26a90a00000000"
+ },
+ "src": "58294:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58287:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8036,
+ "nodeType": "ExpressionStatement",
+ "src": "58287:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8044,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8037,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58396:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8043,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8040,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8038,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58402:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8039,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "58407:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58402:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8041,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "58401:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8042,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "58413:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58401:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58396:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8045,
+ "nodeType": "ExpressionStatement",
+ "src": "58396:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8050,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8046,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "58422:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8049,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8047,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58429:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303031343430623062653136313561343764626136653562336231663130303030303030",
+ "id": 8048,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "58434:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6891635629803648326702674961498112000000_by_1",
+ "typeString": "int_const 6891...(32 digits omitted)...0000"
+ },
+ "value": "0x000000001440b0be1615a47dba6e5b3b1f10000000"
+ },
+ "src": "58429:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58422:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8051,
+ "nodeType": "ExpressionStatement",
+ "src": "58422:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8059,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8052,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58531:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8058,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8055,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8053,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58537:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8054,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "58542:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58537:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8056,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "58536:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8057,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "58548:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58536:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58531:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8060,
+ "nodeType": "ExpressionStatement",
+ "src": "58531:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8065,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8061,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "58557:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8064,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8062,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58564:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303032643230373630316634366139396234313132343138343030303030303030303030",
+ "id": 8063,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "58569:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_15355854537983727757610740636188672000000_by_1",
+ "typeString": "int_const 1535...(33 digits omitted)...0000"
+ },
+ "value": "0x000000002d207601f46a99b4112418400000000000"
+ },
+ "src": "58564:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58557:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8066,
+ "nodeType": "ExpressionStatement",
+ "src": "58557:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8074,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8067,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58666:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8073,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8070,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8068,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58672:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8069,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "58677:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58672:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8071,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "58671:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8072,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "58683:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58671:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58666:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8075,
+ "nodeType": "ExpressionStatement",
+ "src": "58666:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8080,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8076,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "58692:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8079,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8077,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58699:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303036366562616163346333376336323264643832383861376562316232303030303030",
+ "id": 8078,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "58704:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_35022056686251398262544482483830784000000_by_1",
+ "typeString": "int_const 3502...(33 digits omitted)...0000"
+ },
+ "value": "0x0000000066ebaac4c37c622dd8288a7eb1b2000000"
+ },
+ "src": "58699:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58692:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8081,
+ "nodeType": "ExpressionStatement",
+ "src": "58692:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8089,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8082,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58801:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8088,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8085,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8083,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58807:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8084,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "58812:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58807:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8086,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "58806:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8087,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "58818:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58806:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58801:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8090,
+ "nodeType": "ExpressionStatement",
+ "src": "58801:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8095,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8091,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "58827:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8094,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8092,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58834:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303065663137323430313335663764626434336131626131306366323030303030303030",
+ "id": 8093,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "58839:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_81358244885252463857919590400000000000000_by_1",
+ "typeString": "int_const 8135...(33 digits omitted)...0000"
+ },
+ "value": "0x00000000ef17240135f7dbd43a1ba10cf200000000"
+ },
+ "src": "58834:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58827:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8096,
+ "nodeType": "ExpressionStatement",
+ "src": "58827:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8104,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8097,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58936:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8103,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8100,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8098,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58942:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8099,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "58947:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58942:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8101,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "58941:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8102,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "58953:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58941:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58936:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8105,
+ "nodeType": "ExpressionStatement",
+ "src": "58936:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8110,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8106,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "58962:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8109,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8107,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "58969:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303233336333336336373661356562323431363039346138376233363537303030303030",
+ "id": 8108,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "58974:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_191838485670993607105842450247345766400000_by_1",
+ "typeString": "int_const 1918...(34 digits omitted)...0000"
+ },
+ "value": "0x0000000233c33c676a5eb2416094a87b3657000000"
+ },
+ "src": "58969:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "58962:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8111,
+ "nodeType": "ExpressionStatement",
+ "src": "58962:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8119,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8112,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59071:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8118,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8115,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8113,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59077:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8114,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "59082:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59077:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8116,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "59076:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8117,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "59088:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59076:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59071:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8120,
+ "nodeType": "ExpressionStatement",
+ "src": "59071:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8125,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8121,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "59097:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8124,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8122,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59104:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030303534316364653438626330323534626564343961396638373030303030303030303030",
+ "id": 8123,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "59109:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_457953461925960171898563951427426713600000_by_1",
+ "typeString": "int_const 4579...(34 digits omitted)...0000"
+ },
+ "value": "0x0000000541cde48bc0254bed49a9f8700000000000"
+ },
+ "src": "59104:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59097:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8126,
+ "nodeType": "ExpressionStatement",
+ "src": "59097:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8134,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8127,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59206:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8133,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8130,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8128,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59212:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8129,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "59217:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59212:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8131,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "59211:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8132,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "59223:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59211:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59206:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8135,
+ "nodeType": "ExpressionStatement",
+ "src": "59206:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8140,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8136,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "59232:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8139,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8137,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59239:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030306361653166616432636464346434636238643733616263613064313961343030303030",
+ "id": 8138,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "59244:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1104598668270551480892683896320648806400000_by_1",
+ "typeString": "int_const 1104...(35 digits omitted)...0000"
+ },
+ "value": "0x0000000cae1fad2cdd4d4cb8d73abca0d19a400000"
+ },
+ "src": "59239:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59232:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8141,
+ "nodeType": "ExpressionStatement",
+ "src": "59232:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8149,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8142,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59341:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8148,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8145,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8143,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59347:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8144,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "59352:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59347:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8146,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "59346:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8147,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "59358:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59346:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59341:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8150,
+ "nodeType": "ExpressionStatement",
+ "src": "59341:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8155,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8151,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "59367:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8154,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8152,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59374:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030316564623261613266373630643135633431636565646261393536343030303030303030",
+ "id": 8153,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "59379:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2687947090053832841608264823563773542400000_by_1",
+ "typeString": "int_const 2687...(35 digits omitted)...0000"
+ },
+ "value": "0x0000001edb2aa2f760d15c41ceedba956400000000"
+ },
+ "src": "59374:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59367:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8156,
+ "nodeType": "ExpressionStatement",
+ "src": "59367:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8164,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8157,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59476:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8163,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8160,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8158,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59482:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8159,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "59487:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59482:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8161,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "59481:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8162,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "59493:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59481:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59476:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8165,
+ "nodeType": "ExpressionStatement",
+ "src": "59476:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8170,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8166,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "59502:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8169,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8167,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59509:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030346261386432306432646162643338366339353239363539383431613265323030303030",
+ "id": 8168,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "59514:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_6590868088830032065882824000000000000000000_by_1",
+ "typeString": "int_const 6590...(35 digits omitted)...0000"
+ },
+ "value": "0x0000004ba8d20d2dabd386c9529659841a2e200000"
+ },
+ "src": "59509:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59502:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8171,
+ "nodeType": "ExpressionStatement",
+ "src": "59502:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8179,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8172,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59611:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8178,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8175,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8173,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59617:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8174,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "59622:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59617:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8176,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "59616:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8177,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "59628:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59616:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59611:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8180,
+ "nodeType": "ExpressionStatement",
+ "src": "59611:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8185,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8181,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "59637:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8184,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8182,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59644:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303030626163303835343662383637636461613230303030303030303030303030303030303030",
+ "id": 8183,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "59649:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_16268396552280633070412438458028041175040000_by_1",
+ "typeString": "int_const 1626...(36 digits omitted)...0000"
+ },
+ "value": "0x000000bac08546b867cdaa20000000000000000000"
+ },
+ "src": "59644:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59637:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8186,
+ "nodeType": "ExpressionStatement",
+ "src": "59637:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8194,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8187,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59746:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8193,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8190,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8188,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59752:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8189,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "59757:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59752:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8191,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "59751:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8192,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "59763:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59751:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59746:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8195,
+ "nodeType": "ExpressionStatement",
+ "src": "59746:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8200,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8196,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "59772:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8199,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8197,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59779:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303031636661386537306330333632356239646237366338656266356262663234383230303030",
+ "id": 8198,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "59784:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_40390462938090940419774080664538139934720000_by_1",
+ "typeString": "int_const 4039...(36 digits omitted)...0000"
+ },
+ "value": "0x000001cfa8e70c03625b9db76c8ebf5bbf24820000"
+ },
+ "src": "59779:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59772:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8201,
+ "nodeType": "ExpressionStatement",
+ "src": "59772:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8209,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8202,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59881:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8208,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8205,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8203,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59887:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8204,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "59892:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59887:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8206,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "59886:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8207,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "59898:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59886:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59881:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8210,
+ "nodeType": "ExpressionStatement",
+ "src": "59881:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8215,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8211,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "59907:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8214,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8212,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "59914:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303034383531643939663832303630646632363566333330396232366638323030303030303030",
+ "id": 8213,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "59919:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_100798987671917000666814256179934522245120000_by_1",
+ "typeString": "int_const 1007...(37 digits omitted)...0000"
+ },
+ "value": "0x000004851d99f82060df265f3309b26f8200000000"
+ },
+ "src": "59914:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "59907:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8216,
+ "nodeType": "ExpressionStatement",
+ "src": "59907:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8224,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8217,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60016:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8223,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8220,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8218,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60022:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8219,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "60027:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60022:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8221,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "60021:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8222,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "60033:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60021:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60016:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8225,
+ "nodeType": "ExpressionStatement",
+ "src": "60016:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8230,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8226,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "60042:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8229,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8227,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60049:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303062353530643139623132396432373063343466366635356630323737323363626230303030",
+ "id": 8228,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "60054:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_252717199309391137912965664538441463029760000_by_1",
+ "typeString": "int_const 2527...(37 digits omitted)...0000"
+ },
+ "value": "0x00000b550d19b129d270c44f6f55f027723cbb0000"
+ },
+ "src": "60049:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60042:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8231,
+ "nodeType": "ExpressionStatement",
+ "src": "60042:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8239,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8232,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60151:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8238,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8235,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8233,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60157:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8234,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "60162:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60157:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8236,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "60156:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8237,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "60168:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60156:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60151:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8240,
+ "nodeType": "ExpressionStatement",
+ "src": "60151:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8245,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8241,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "60177:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8244,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8242,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60184:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303163383737646164633736316463323732646562363564346230303030303030303030303030",
+ "id": 8243,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "60189:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_636223790447205380259840000000000000000000000_by_1",
+ "typeString": "int_const 6362...(37 digits omitted)...0000"
+ },
+ "value": "0x00001c877dadc761dc272deb65d4b0000000000000"
+ },
+ "src": "60184:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60177:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8246,
+ "nodeType": "ExpressionStatement",
+ "src": "60177:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8254,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8247,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60286:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8253,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8250,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8248,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60292:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8249,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "60297:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60292:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8251,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "60291:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8252,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "60303:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60291:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60286:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8255,
+ "nodeType": "ExpressionStatement",
+ "src": "60286:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8260,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8256,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "60312:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8259,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8257,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60319:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030303438313738656365393734373966333361373766326164323261383162363434303663303030",
+ "id": 8258,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "60324:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1607705831573194746802610334450509017233408000_by_1",
+ "typeString": "int_const 1607...(38 digits omitted)...8000"
+ },
+ "value": "0x000048178ece97479f33a77f2ad22a81b64406c000"
+ },
+ "src": "60319:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60312:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8261,
+ "nodeType": "ExpressionStatement",
+ "src": "60312:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8269,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8262,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60421:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8268,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8265,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8263,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60427:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8264,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "60432:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60427:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8266,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "60426:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8267,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "60438:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60426:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60421:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8270,
+ "nodeType": "ExpressionStatement",
+ "src": "60421:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8275,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8271,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "60447:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8274,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8272,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60454:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030306236636138323638623964383130666564663636393565663266386136633030303030303030",
+ "id": 8273,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "60459:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4076376683803157531046819273912505658769408000_by_1",
+ "typeString": "int_const 4076...(38 digits omitted)...8000"
+ },
+ "value": "0x0000b6ca8268b9d810fedf6695ef2f8a6c00000000"
+ },
+ "src": "60454:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60447:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8276,
+ "nodeType": "ExpressionStatement",
+ "src": "60447:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8284,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8277,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60556:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8283,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8280,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8278,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60562:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8279,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "60567:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60562:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8281,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "60561:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8282,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "60573:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60561:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60556:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8285,
+ "nodeType": "ExpressionStatement",
+ "src": "60556:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8290,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8286,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "60582:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8289,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8287,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60589:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030316430653736363331613562303564303037623863623732613763376631316563333665303030",
+ "id": 8288,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "60594:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_10367703484962349537949059901011799777283072000_by_1",
+ "typeString": "int_const 1036...(39 digits omitted)...2000"
+ },
+ "value": "0x0001d0e76631a5b05d007b8cb72a7c7f11ec36e000"
+ },
+ "src": "60589:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60582:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8291,
+ "nodeType": "ExpressionStatement",
+ "src": "60582:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8299,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8292,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60691:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8298,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8295,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8293,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60697:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8294,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "60702:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60697:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8296,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "60696:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8297,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "60708:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60696:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60691:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8300,
+ "nodeType": "ExpressionStatement",
+ "src": "60691:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8305,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8301,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "60717:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8304,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8302,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60724:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030346131633337626439663835666439633663373830303030303030303030303030303030303030",
+ "id": 8303,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "60729:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_26443412100478721735433130630260686447443968000_by_1",
+ "typeString": "int_const 2644...(39 digits omitted)...8000"
+ },
+ "value": "0x0004a1c37bd9f85fd9c6c780000000000000000000"
+ },
+ "src": "60724:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60717:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8306,
+ "nodeType": "ExpressionStatement",
+ "src": "60717:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8314,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8307,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60826:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8313,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8310,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8308,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60832:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8309,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "60837:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60832:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8311,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "60831:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8312,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "60843:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60831:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60826:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8315,
+ "nodeType": "ExpressionStatement",
+ "src": "60826:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8320,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8316,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "60852:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8319,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8317,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60859:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303030626438333639663162373032626634393165326562666365653038323530333133623635343030",
+ "id": 8318,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "60864:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_67620617646753089502453804016113281250000000000_by_1",
+ "typeString": "int_const 6762...(39 digits omitted)...0000"
+ },
+ "value": "0x000bd8369f1b702bf491e2ebfcee08250313b65400"
+ },
+ "src": "60859:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60852:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8321,
+ "nodeType": "ExpressionStatement",
+ "src": "60852:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8329,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8322,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60961:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8328,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8325,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8323,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60967:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8324,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "60972:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60967:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8326,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "60966:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8327,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "60978:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60966:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60961:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8330,
+ "nodeType": "ExpressionStatement",
+ "src": "60961:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8335,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8331,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "60987:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8334,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8332,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "60994:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303031653563376333326139663663373061623263623539643932323537363464343030303030303030",
+ "id": 8333,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "60999:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_173332210846474760735500226875327576716638945280_by_1",
+ "typeString": "int_const 1733...(40 digits omitted)...5280"
+ },
+ "value": "0x001e5c7c32a9f6c70ab2cb59d9225764d400000000"
+ },
+ "src": "60994:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "60987:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8336,
+ "nodeType": "ExpressionStatement",
+ "src": "60987:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8344,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8337,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61096:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8343,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8340,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8338,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61102:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8339,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "61107:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61102:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8341,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "61101:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8342,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "61113:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61101:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61096:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8345,
+ "nodeType": "ExpressionStatement",
+ "src": "61096:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8350,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8346,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "61122:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8349,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8347,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61129:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303034646666353832306531363565393130663935313230613730386537343234393632323165363030",
+ "id": 8348,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "61134:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_445286656448864136819345605176268818347976680960_by_1",
+ "typeString": "int_const 4452...(40 digits omitted)...0960"
+ },
+ "value": "0x004dff5820e165e910f95120a708e742496221e600"
+ },
+ "src": "61129:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61122:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8351,
+ "nodeType": "ExpressionStatement",
+ "src": "61122:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8359,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8352,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61231:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8358,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8355,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8353,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61237:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8354,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "61242:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61237:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8356,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "61236:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8357,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "61248:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61236:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61231:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8360,
+ "nodeType": "ExpressionStatement",
+ "src": "61231:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8365,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8361,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "61257:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8364,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8362,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61264:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303063386338663636646231666365643337386565353065353336303030303030303030303030303030",
+ "id": 8363,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "61269:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1146279770154177862273033179056478989553563074560_by_1",
+ "typeString": "int_const 1146...(41 digits omitted)...4560"
+ },
+ "value": "0x00c8c8f66db1fced378ee50e536000000000000000"
+ },
+ "src": "61264:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61257:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8366,
+ "nodeType": "ExpressionStatement",
+ "src": "61257:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8374,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8367,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61366:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8373,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8370,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8368,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61372:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8369,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "61377:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61372:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8371,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "61371:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8372,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "61383:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61371:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61366:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8375,
+ "nodeType": "ExpressionStatement",
+ "src": "61366:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8380,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8376,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "61392:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8379,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8377,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61399:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303230356462386466666666343562666132393338663132386635393964626631366562313164383830",
+ "id": 8378,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "61404:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2956444461658038477759873400213214992927382689920_by_1",
+ "typeString": "int_const 2956...(41 digits omitted)...9920"
+ },
+ "value": "0x0205db8dffff45bfa2938f128f599dbf16eb11d880"
+ },
+ "src": "61399:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61392:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8381,
+ "nodeType": "ExpressionStatement",
+ "src": "61392:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8389,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8382,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61501:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8388,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8385,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8383,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61507:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8384,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "61512:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61507:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8386,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "61506:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8387,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "61518:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61506:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61501:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8390,
+ "nodeType": "ExpressionStatement",
+ "src": "61501:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8395,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8391,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "61527:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8394,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8392,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61534:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078303533613034346562643938343335313439336531373836616633386433396130383030303030303030",
+ "id": 8393,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "61539:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_7638725713617153619200000000000000000000000000000_by_1",
+ "typeString": "int_const 7638...(41 digits omitted)...0000"
+ },
+ "value": "0x053a044ebd984351493e1786af38d39a0800000000"
+ },
+ "src": "61534:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61527:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8396,
+ "nodeType": "ExpressionStatement",
+ "src": "61527:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8404,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8397,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61636:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8403,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8400,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8398,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61642:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8399,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "61647:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61642:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8401,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "61641:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8402,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "61653:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61641:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61636:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8405,
+ "nodeType": "ExpressionStatement",
+ "src": "61636:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8410,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8406,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "61662:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8409,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8407,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61669:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078306438366461653261346363306634373633336135343434373937333538363962343837623539633430",
+ "id": 8408,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "61674:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_19769407354499582705095371848882117322613875645504_by_1",
+ "typeString": "int_const 1976...(42 digits omitted)...5504"
+ },
+ "value": "0x0d86dae2a4cc0f47633a544479735869b487b59c40"
+ },
+ "src": "61669:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61662:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8411,
+ "nodeType": "ExpressionStatement",
+ "src": "61662:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8419,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8412,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61771:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8418,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8415,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8413,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61777:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8414,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "61782:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61777:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8416,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "61776:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8417,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "61788:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61776:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61771:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8420,
+ "nodeType": "ExpressionStatement",
+ "src": "61771:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8425,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8421,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "61797:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8424,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8422,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61804:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078323331303030303030303030303030303030303030303030303030303030303030303030303030303030",
+ "id": 8423,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "61809:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_51243901158914783569516699447114673376686134788096_by_1",
+ "typeString": "int_const 5124...(42 digits omitted)...8096"
+ },
+ "value": "0x231000000000000000000000000000000000000000"
+ },
+ "src": "61804:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61797:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8426,
+ "nodeType": "ExpressionStatement",
+ "src": "61797:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8434,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8427,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61906:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8433,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8430,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8428,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61912:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8429,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "61917:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61912:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8431,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "61911:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8432,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "61923:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61911:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61906:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8435,
+ "nodeType": "ExpressionStatement",
+ "src": "61906:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8440,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8436,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "61932:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8439,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8437,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "61939:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078356230343835613736663636343663323033396462313530376364643531623038363439363830383232",
+ "id": 8438,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "61944:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_133022465544965907471119545993290733585983764695074_by_1",
+ "typeString": "int_const 1330...(43 digits omitted)...5074"
+ },
+ "value": "0x5b0485a76f6646c2039db1507cdd51b08649680822"
+ },
+ "src": "61939:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "61932:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8441,
+ "nodeType": "ExpressionStatement",
+ "src": "61932:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8449,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8442,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "62041:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8448,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8445,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8443,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "62047:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8444,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "62052:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62047:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8446,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "62046:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8447,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "62058:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62046:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62041:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8450,
+ "nodeType": "ExpressionStatement",
+ "src": "62041:24:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8455,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8451,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "62067:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8454,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8452,
+ "name": "xi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7970,
+ "src": "62074:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3078656339383363343663343935343562633137656661366235623030353565323432323030303030303030",
+ "id": 8453,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "62079:44:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_345783497216724000335707367685598692782880644399104_by_1",
+ "typeString": "int_const 3457...(43 digits omitted)...9104"
+ },
+ "value": "0xec983c46c49545bc17efa6b5b0055e242200000000"
+ },
+ "src": "62074:49:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62067:56:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8456,
+ "nodeType": "ExpressionStatement",
+ "src": "62067:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8463,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8461,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8459,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8457,
+ "name": "res",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7974,
+ "src": "62185:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30786465316263346431396566636163383234343564613735623030303030303030",
+ "id": 8458,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "62191:34:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_295232799039604140847618609643520000000_by_1",
+ "typeString": "int_const 2952...(31 digits omitted)...0000"
+ },
+ "value": "0xde1bc4d19efcac82445da75b00000000"
+ },
+ "src": "62185:40:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8460,
+ "name": "_x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7964,
+ "src": "62228:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62185:45:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8462,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "62233:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62185:55:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 7968,
+ "id": 8464,
+ "nodeType": "Return",
+ "src": "62178:62:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 7962,
+ "nodeType": "StructuredDocumentation",
+ "src": "57537:183:7",
+ "text": " @dev computes W(-x / FIXED_1) / (-x / FIXED_1) * FIXED_1\n input range: 1 <= x <= 1 / e * FIXED_1\n auto-generated via 'PrintFunctionLambertNeg1.py'"
+ },
+ "id": 8466,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "lambertNeg1",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 7965,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7964,
+ "mutability": "mutable",
+ "name": "_x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8466,
+ "src": "57747:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7963,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "57747:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "57746:12:7"
+ },
+ "returnParameters": {
+ "id": 7968,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 7967,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8466,
+ "src": "57782:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 7966,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "57782:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "57781:9:7"
+ },
+ "scope": 8977,
+ "src": "57726:4616:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 8546,
+ "nodeType": "Block",
+ "src": "62643:343:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8491,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 8484,
+ "name": "_tq",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8473,
+ "src": "62655:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8485,
+ "name": "_rp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8475,
+ "src": "62660:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8486,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "62654:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8488,
+ "name": "_tq",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8473,
+ "src": "62679:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8489,
+ "name": "_rp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8475,
+ "src": "62684:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8487,
+ "name": "safeFactors",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8621,
+ "src": "62667:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256,uint256)"
+ }
+ },
+ "id": 8490,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62667:21:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "src": "62654:34:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 8492,
+ "nodeType": "ExpressionStatement",
+ "src": "62654:34:7"
+ },
+ {
+ "assignments": [
+ 8494
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8494,
+ "mutability": "mutable",
+ "name": "f",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8546,
+ "src": "62699:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8493,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "62699:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8501,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8500,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8497,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "62719:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 8495,
+ "name": "_hi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8469,
+ "src": "62711:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8496,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "62711:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8498,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62711:16:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8499,
+ "name": "_lo",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8471,
+ "src": "62730:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62711:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "62699:34:7"
+ },
+ {
+ "assignments": [
+ 8503
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8503,
+ "mutability": "mutable",
+ "name": "g",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8546,
+ "src": "62744:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8502,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "62744:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8514,
+ "initialValue": {
+ "argumentTypes": null,
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8506,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8504,
+ "name": "f",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8494,
+ "src": "62756:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8505,
+ "name": "OPT_LOG_MAX_VAL",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3601,
+ "src": "62760:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62756:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8511,
+ "name": "f",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8494,
+ "src": "62805:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8510,
+ "name": "generalLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5906,
+ "src": "62794:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8512,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62794:13:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8513,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "Conditional",
+ "src": "62756:51:7",
+ "trueExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8508,
+ "name": "f",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8494,
+ "src": "62789:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8507,
+ "name": "optimalLog",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 6866,
+ "src": "62778:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8509,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62778:13:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "62744:63:7"
+ },
+ {
+ "assignments": [
+ 8516
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8516,
+ "mutability": "mutable",
+ "name": "x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8546,
+ "src": "62818:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8515,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "62818:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8523,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8522,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8519,
+ "name": "_tq",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8473,
+ "src": "62836:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 8517,
+ "name": "g",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8503,
+ "src": "62830:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8518,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "62830:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8520,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62830:10:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8521,
+ "name": "_rp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8475,
+ "src": "62843:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "62830:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "62818:28:7"
+ },
+ {
+ "assignments": [
+ 8525
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8525,
+ "mutability": "mutable",
+ "name": "y",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8546,
+ "src": "62857:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8524,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "62857:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8534,
+ "initialValue": {
+ "argumentTypes": null,
+ "condition": {
+ "argumentTypes": null,
+ "id": 8526,
+ "name": "_lowerStake",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8477,
+ "src": "62869:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8531,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8516,
+ "src": "62911:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8530,
+ "name": "higherStake",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7336,
+ "src": "62899:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8532,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62899:14:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8533,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "Conditional",
+ "src": "62869:44:7",
+ "trueExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8528,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8516,
+ "src": "62894:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8527,
+ "name": "lowerStake",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 7313,
+ "src": "62883:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256) view returns (uint256)"
+ }
+ },
+ "id": 8529,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62883:13:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "62857:56:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8538,
+ "name": "_tq",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8473,
+ "src": "62955:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 8536,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8525,
+ "src": "62949:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8537,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "62949:5:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8539,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62949:10:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8542,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "62969:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 8540,
+ "name": "_rp",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8475,
+ "src": "62961:3:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8541,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "62961:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8543,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62961:16:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8535,
+ "name": "normalizedWeights",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8656,
+ "src": "62931:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint32_$_t_uint32_$",
+ "typeString": "function (uint256,uint256) pure returns (uint32,uint32)"
+ }
+ },
+ "id": 8544,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "62931:47:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint32_$_t_uint32_$",
+ "typeString": "tuple(uint32,uint32)"
+ }
+ },
+ "functionReturnParameters": 8483,
+ "id": 8545,
+ "nodeType": "Return",
+ "src": "62924:54:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8467,
+ "nodeType": "StructuredDocumentation",
+ "src": "62350:146:7",
+ "text": " @dev computes the weights based on \"W(log(hi / lo) * tq / rp) * tq / rp\", where \"W\" is a variation of the Lambert W function."
+ },
+ "id": 8547,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "balancedWeightsByStake",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8478,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8469,
+ "mutability": "mutable",
+ "name": "_hi",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8547,
+ "src": "62534:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8468,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "62534:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8471,
+ "mutability": "mutable",
+ "name": "_lo",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8547,
+ "src": "62547:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8470,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "62547:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8473,
+ "mutability": "mutable",
+ "name": "_tq",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8547,
+ "src": "62560:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8472,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "62560:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8475,
+ "mutability": "mutable",
+ "name": "_rp",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8547,
+ "src": "62573:11:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8474,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "62573:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8477,
+ "mutability": "mutable",
+ "name": "_lowerStake",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8547,
+ "src": "62586:16:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 8476,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "62586:4:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "62533:70:7"
+ },
+ "returnParameters": {
+ "id": 8483,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8480,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8547,
+ "src": "62627:6:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8479,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "62627:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8482,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8547,
+ "src": "62635:6:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8481,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "62635:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "62626:16:7"
+ },
+ "scope": 8977,
+ "src": "62502:484:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 8620,
+ "nodeType": "Block",
+ "src": "63162:358:7",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 8565,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8561,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8559,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8550,
+ "src": "63177:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8560,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "63183:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63177:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8564,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8562,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8552,
+ "src": "63194:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8563,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "63200:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63194:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "63177:30:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 8570,
+ "nodeType": "IfStatement",
+ "src": "63173:64:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 8566,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8550,
+ "src": "63230:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8567,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8552,
+ "src": "63234:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8568,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "63229:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "functionReturnParameters": 8558,
+ "id": 8569,
+ "nodeType": "Return",
+ "src": "63222:15:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8573,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8571,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8550,
+ "src": "63252:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8572,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "63257:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63252:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 8582,
+ "nodeType": "IfStatement",
+ "src": "63248:66:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8578,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8576,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8574,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8550,
+ "src": "63287:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8575,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "63292:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63287:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8577,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8552,
+ "src": "63302:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63287:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8579,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "63306:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8580,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "63286:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "functionReturnParameters": 8558,
+ "id": 8581,
+ "nodeType": "Return",
+ "src": "63279:35:7"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8585,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8583,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8552,
+ "src": "63329:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8584,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "63334:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63329:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 8594,
+ "nodeType": "IfStatement",
+ "src": "63325:66:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 8586,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "63364:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8591,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8589,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8587,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8552,
+ "src": "63373:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8588,
+ "name": "FIXED_2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3589,
+ "src": "63378:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63373:12:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8590,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8550,
+ "src": "63388:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63373:17:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8592,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "63363:28:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "functionReturnParameters": 8558,
+ "id": 8593,
+ "nodeType": "Return",
+ "src": "63356:35:7"
+ }
+ },
+ {
+ "assignments": [
+ 8596
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8596,
+ "mutability": "mutable",
+ "name": "c",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8620,
+ "src": "63402:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8595,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "63402:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8603,
+ "initialValue": {
+ "argumentTypes": null,
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8599,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8597,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8550,
+ "src": "63414:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8598,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8552,
+ "src": "63419:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63414:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseExpression": {
+ "argumentTypes": null,
+ "id": 8601,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8552,
+ "src": "63429:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8602,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "Conditional",
+ "src": "63414:17:7",
+ "trueExpression": {
+ "argumentTypes": null,
+ "id": 8600,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8550,
+ "src": "63424:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "63402:29:7"
+ },
+ {
+ "assignments": [
+ 8605
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8605,
+ "mutability": "mutable",
+ "name": "n",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8620,
+ "src": "63442:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8604,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "63442:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8611,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8609,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8607,
+ "name": "c",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8596,
+ "src": "63464:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8608,
+ "name": "FIXED_1",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3586,
+ "src": "63468:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63464:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8606,
+ "name": "floorLog2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5969,
+ "src": "63454:9:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint8_$",
+ "typeString": "function (uint256) pure returns (uint8)"
+ }
+ },
+ "id": 8610,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "63454:22:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "63442:34:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8614,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8612,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8550,
+ "src": "63495:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8613,
+ "name": "n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8605,
+ "src": "63501:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63495:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8617,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8615,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8552,
+ "src": "63504:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">>",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8616,
+ "name": "n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8605,
+ "src": "63510:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63504:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8618,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "63494:18:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "functionReturnParameters": 8558,
+ "id": 8619,
+ "nodeType": "Return",
+ "src": "63487:25:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8548,
+ "nodeType": "StructuredDocumentation",
+ "src": "62994:76:7",
+ "text": " @dev reduces \"a\" and \"b\" while maintaining their ratio."
+ },
+ "id": 8621,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "safeFactors",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8553,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8550,
+ "mutability": "mutable",
+ "name": "_a",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8621,
+ "src": "63097:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8549,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "63097:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8552,
+ "mutability": "mutable",
+ "name": "_b",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8621,
+ "src": "63109:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8551,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "63109:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "63096:24:7"
+ },
+ "returnParameters": {
+ "id": 8558,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8555,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8621,
+ "src": "63144:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8554,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "63144:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8557,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8621,
+ "src": "63153:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8556,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "63153:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "63143:18:7"
+ },
+ "scope": 8977,
+ "src": "63076:444:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 8655,
+ "nodeType": "Block",
+ "src": "63717:157:7",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8635,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8633,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8624,
+ "src": "63732:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8634,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8626,
+ "src": "63738:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "63732:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 8641,
+ "nodeType": "IfStatement",
+ "src": "63728:57:7",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8637,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8624,
+ "src": "63778:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8638,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8626,
+ "src": "63782:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8636,
+ "name": "accurateWeights",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8721,
+ "src": "63762:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint32_$_t_uint32_$",
+ "typeString": "function (uint256,uint256) pure returns (uint32,uint32)"
+ }
+ },
+ "id": 8639,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "63762:23:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint32_$_t_uint32_$",
+ "typeString": "tuple(uint32,uint32)"
+ }
+ },
+ "functionReturnParameters": 8632,
+ "id": 8640,
+ "nodeType": "Return",
+ "src": "63755:30:7"
+ }
+ },
+ {
+ "assignments": [
+ 8643,
+ 8645
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8643,
+ "mutability": "mutable",
+ "name": "y",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8655,
+ "src": "63797:8:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8642,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "63797:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8645,
+ "mutability": "mutable",
+ "name": "x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8655,
+ "src": "63807:8:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8644,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "63807:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8650,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8647,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8626,
+ "src": "63835:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8648,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8624,
+ "src": "63839:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8646,
+ "name": "accurateWeights",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8721,
+ "src": "63819:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint32_$_t_uint32_$",
+ "typeString": "function (uint256,uint256) pure returns (uint32,uint32)"
+ }
+ },
+ "id": 8649,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "63819:23:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint32_$_t_uint32_$",
+ "typeString": "tuple(uint32,uint32)"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "63796:46:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 8651,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8645,
+ "src": "63861:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8652,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8643,
+ "src": "63864:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "id": 8653,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "63860:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint32_$_t_uint32_$",
+ "typeString": "tuple(uint32,uint32)"
+ }
+ },
+ "functionReturnParameters": 8632,
+ "id": 8654,
+ "nodeType": "Return",
+ "src": "63853:13:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8622,
+ "nodeType": "StructuredDocumentation",
+ "src": "63528:93:7",
+ "text": " @dev computes \"MAX_WEIGHT * a / (a + b)\" and \"MAX_WEIGHT * b / (a + b)\"."
+ },
+ "id": 8656,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "normalizedWeights",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8627,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8624,
+ "mutability": "mutable",
+ "name": "_a",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8656,
+ "src": "63654:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8623,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "63654:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8626,
+ "mutability": "mutable",
+ "name": "_b",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8656,
+ "src": "63666:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8625,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "63666:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "63653:24:7"
+ },
+ "returnParameters": {
+ "id": 8632,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8629,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8656,
+ "src": "63701:6:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8628,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "63701:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8631,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8656,
+ "src": "63709:6:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8630,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "63709:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "63700:16:7"
+ },
+ "scope": 8977,
+ "src": "63627:247:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 8720,
+ "nodeType": "Block",
+ "src": "64093:292:7",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8670,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8668,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8659,
+ "src": "64108:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8669,
+ "name": "MAX_UNF_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3619,
+ "src": "64113:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64108:19:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 8691,
+ "nodeType": "IfStatement",
+ "src": "64104:137:7",
+ "trueBody": {
+ "id": 8690,
+ "nodeType": "Block",
+ "src": "64129:112:7",
+ "statements": [
+ {
+ "assignments": [
+ 8672
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8672,
+ "mutability": "mutable",
+ "name": "c",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8690,
+ "src": "64144:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8671,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64144:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8681,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8680,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8678,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8673,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8659,
+ "src": "64156:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8676,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8674,
+ "name": "MAX_UNF_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3619,
+ "src": "64162:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 8675,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "64179:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "64162:18:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8677,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "64161:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64156:25:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 8679,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "64184:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "64156:29:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "64144:41:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8684,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8682,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8659,
+ "src": "64200:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "/=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 8683,
+ "name": "c",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8672,
+ "src": "64206:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64200:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8685,
+ "nodeType": "ExpressionStatement",
+ "src": "64200:7:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 8688,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 8686,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8661,
+ "src": "64222:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "/=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 8687,
+ "name": "c",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8672,
+ "src": "64228:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64222:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8689,
+ "nodeType": "ExpressionStatement",
+ "src": "64222:7:7"
+ }
+ ]
+ }
+ },
+ {
+ "assignments": [
+ 8693
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8693,
+ "mutability": "mutable",
+ "name": "x",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8720,
+ "src": "64251:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8692,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64251:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8703,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8697,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8695,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8659,
+ "src": "64272:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "*",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8696,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "64277:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "src": "64272:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8700,
+ "name": "_b",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8661,
+ "src": "64296:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 8698,
+ "name": "_a",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8659,
+ "src": "64289:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 8699,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "add",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22271,
+ "src": "64289:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8701,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "64289:10:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8694,
+ "name": "roundDiv",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8747,
+ "src": "64263:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 8702,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "64263:37:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "64251:49:7"
+ },
+ {
+ "assignments": [
+ 8705
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 8705,
+ "mutability": "mutable",
+ "name": "y",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8720,
+ "src": "64311:9:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8704,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64311:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 8709,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8708,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8706,
+ "name": "MAX_WEIGHT",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3577,
+ "src": "64323:10:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8707,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8693,
+ "src": "64336:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64323:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "64311:26:7"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8712,
+ "name": "x",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8693,
+ "src": "64363:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8711,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "64356:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_uint32_$",
+ "typeString": "type(uint32)"
+ },
+ "typeName": {
+ "id": 8710,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "64356:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 8713,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "64356:9:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8716,
+ "name": "y",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8705,
+ "src": "64374:1:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8715,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "64367:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_uint32_$",
+ "typeString": "type(uint32)"
+ },
+ "typeName": {
+ "id": 8714,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "64367:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 8717,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "64367:9:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "id": 8718,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "64355:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint32_$_t_uint32_$",
+ "typeString": "tuple(uint32,uint32)"
+ }
+ },
+ "functionReturnParameters": 8667,
+ "id": 8719,
+ "nodeType": "Return",
+ "src": "64348:29:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8657,
+ "nodeType": "StructuredDocumentation",
+ "src": "63882:117:7",
+ "text": " @dev computes \"MAX_WEIGHT * a / (a + b)\" and \"MAX_WEIGHT * b / (a + b)\", assuming that \"a <= b\"."
+ },
+ "id": 8721,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "accurateWeights",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8662,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8659,
+ "mutability": "mutable",
+ "name": "_a",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8721,
+ "src": "64030:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8658,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64030:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8661,
+ "mutability": "mutable",
+ "name": "_b",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8721,
+ "src": "64042:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8660,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64042:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "64029:24:7"
+ },
+ "returnParameters": {
+ "id": 8667,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8664,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8721,
+ "src": "64077:6:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8663,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "64077:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8666,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8721,
+ "src": "64085:6:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8665,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "64085:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "64076:16:7"
+ },
+ "scope": 8977,
+ "src": "64005:380:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 8746,
+ "nodeType": "Block",
+ "src": "64584:59:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8744,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8733,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8731,
+ "name": "_n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8724,
+ "src": "64602:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8732,
+ "name": "_d",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8726,
+ "src": "64607:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64602:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8743,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8736,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8734,
+ "name": "_n",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8724,
+ "src": "64612:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "%",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 8735,
+ "name": "_d",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8726,
+ "src": "64617:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64612:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8741,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8737,
+ "name": "_d",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8726,
+ "src": "64623:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 8740,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 8738,
+ "name": "_d",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8726,
+ "src": "64628:2:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 8739,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "64633:1:7",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "64628:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64623:11:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 8742,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "64622:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64612:23:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "64602:33:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8730,
+ "id": 8745,
+ "nodeType": "Return",
+ "src": "64595:40:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8722,
+ "nodeType": "StructuredDocumentation",
+ "src": "64393:111:7",
+ "text": " @dev computes the nearest integer to a given quotient without overflowing or underflowing."
+ },
+ "id": 8747,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "roundDiv",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8727,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8724,
+ "mutability": "mutable",
+ "name": "_n",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8747,
+ "src": "64528:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8723,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64528:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8726,
+ "mutability": "mutable",
+ "name": "_d",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8747,
+ "src": "64540:10:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8725,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64540:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "64527:24:7"
+ },
+ "returnParameters": {
+ "id": 8730,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8729,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8747,
+ "src": "64575:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8728,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64575:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "64574:9:7"
+ },
+ "scope": 8977,
+ "src": "64510:133:7",
+ "stateMutability": "pure",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 8768,
+ "nodeType": "Block",
+ "src": "65019:97:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8762,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8750,
+ "src": "65058:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8763,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8752,
+ "src": "65067:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8764,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8754,
+ "src": "65084:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8765,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8756,
+ "src": "65100:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8761,
+ "name": "purchaseTargetAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5085,
+ "src": "65037:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8766,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "65037:71:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8760,
+ "id": 8767,
+ "nodeType": "Return",
+ "src": "65030:78:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8748,
+ "nodeType": "StructuredDocumentation",
+ "src": "64651:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "29a00e7c",
+ "id": 8769,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "calculatePurchaseReturn",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8757,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8750,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8769,
+ "src": "64750:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8749,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64750:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8752,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8769,
+ "src": "64805:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8751,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64805:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8754,
+ "mutability": "mutable",
+ "name": "_reserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8769,
+ "src": "64868:21:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8753,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "64868:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8756,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8769,
+ "src": "64929:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8755,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "64929:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "64749:196:7"
+ },
+ "returnParameters": {
+ "id": 8760,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8759,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8769,
+ "src": "65005:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8758,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "65005:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "65004:9:7"
+ },
+ "scope": 8977,
+ "src": "64717:399:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8790,
+ "nodeType": "Block",
+ "src": "65472:93:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8784,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8772,
+ "src": "65507:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8785,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8774,
+ "src": "65516:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8786,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8776,
+ "src": "65533:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8787,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8778,
+ "src": "65549:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8783,
+ "name": "saleTargetAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5199,
+ "src": "65490:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8788,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "65490:67:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8782,
+ "id": 8789,
+ "nodeType": "Return",
+ "src": "65483:74:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8770,
+ "nodeType": "StructuredDocumentation",
+ "src": "65124:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "49f9b0f7",
+ "id": 8791,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "calculateSaleReturn",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8779,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8772,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8791,
+ "src": "65219:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8771,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "65219:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8774,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8791,
+ "src": "65270:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8773,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "65270:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8776,
+ "mutability": "mutable",
+ "name": "_reserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8791,
+ "src": "65329:21:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8775,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "65329:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8778,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8791,
+ "src": "65386:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8777,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "65386:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "65218:184:7"
+ },
+ "returnParameters": {
+ "id": 8782,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8781,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8791,
+ "src": "65458:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8780,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "65458:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "65457:9:7"
+ },
+ "scope": 8977,
+ "src": "65190:375:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8815,
+ "nodeType": "Block",
+ "src": "66058:149:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8808,
+ "name": "_sourceReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8794,
+ "src": "66101:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8809,
+ "name": "_sourceReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8796,
+ "src": "66124:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8810,
+ "name": "_targetReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8798,
+ "src": "66146:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8811,
+ "name": "_targetReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8800,
+ "src": "66169:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8812,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8802,
+ "src": "66191:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8807,
+ "name": "crossReserveTargetAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5305,
+ "src": "66076:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint32_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint32,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8813,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "66076:123:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8806,
+ "id": 8814,
+ "nodeType": "Return",
+ "src": "66069:130:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8792,
+ "nodeType": "StructuredDocumentation",
+ "src": "65573:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "79c1b450",
+ "id": 8816,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "calculateCrossReserveReturn",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8803,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8794,
+ "mutability": "mutable",
+ "name": "_sourceReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8816,
+ "src": "65676:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8793,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "65676:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8796,
+ "mutability": "mutable",
+ "name": "_sourceReserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8816,
+ "src": "65749:27:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8795,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "65749:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8798,
+ "mutability": "mutable",
+ "name": "_targetReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8816,
+ "src": "65820:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8797,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "65820:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8800,
+ "mutability": "mutable",
+ "name": "_targetReserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8816,
+ "src": "65893:27:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8799,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "65893:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8802,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8816,
+ "src": "65964:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8801,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "65964:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "65675:305:7"
+ },
+ "returnParameters": {
+ "id": 8806,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8805,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8816,
+ "src": "66044:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8804,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "66044:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "66043:9:7"
+ },
+ "scope": 8977,
+ "src": "65639:568:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8840,
+ "nodeType": "Block",
+ "src": "66712:149:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8833,
+ "name": "_sourceReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8819,
+ "src": "66755:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8834,
+ "name": "_sourceReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8821,
+ "src": "66778:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8835,
+ "name": "_targetReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8823,
+ "src": "66800:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8836,
+ "name": "_targetReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8825,
+ "src": "66823:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8837,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8827,
+ "src": "66845:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8832,
+ "name": "crossReserveTargetAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5305,
+ "src": "66730:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint32_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint32,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8838,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "66730:123:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8831,
+ "id": 8839,
+ "nodeType": "Return",
+ "src": "66723:130:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8817,
+ "nodeType": "StructuredDocumentation",
+ "src": "66215:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "65098bb3",
+ "id": 8841,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "calculateCrossConnectorReturn",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8828,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8819,
+ "mutability": "mutable",
+ "name": "_sourceReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8841,
+ "src": "66320:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8818,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "66320:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8821,
+ "mutability": "mutable",
+ "name": "_sourceReserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8841,
+ "src": "66395:27:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8820,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "66395:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8823,
+ "mutability": "mutable",
+ "name": "_targetReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8841,
+ "src": "66468:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8822,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "66468:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8825,
+ "mutability": "mutable",
+ "name": "_targetReserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8841,
+ "src": "66543:27:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8824,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "66543:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8827,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8841,
+ "src": "66616:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8826,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "66616:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "66319:313:7"
+ },
+ "returnParameters": {
+ "id": 8831,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8830,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8841,
+ "src": "66698:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8829,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "66698:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "66697:9:7"
+ },
+ "scope": 8977,
+ "src": "66281:580:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8862,
+ "nodeType": "Block",
+ "src": "67206:84:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8856,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8844,
+ "src": "67233:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8857,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8846,
+ "src": "67242:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8858,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8848,
+ "src": "67259:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8859,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8850,
+ "src": "67274:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8855,
+ "name": "fundCost",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5413,
+ "src": "67224:8:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8860,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "67224:58:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8854,
+ "id": 8861,
+ "nodeType": "Return",
+ "src": "67217:65:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8842,
+ "nodeType": "StructuredDocumentation",
+ "src": "66869:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "1da6bbfb",
+ "id": 8863,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "calculateFundCost",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8851,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8844,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8863,
+ "src": "66962:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8843,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "66962:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8846,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8863,
+ "src": "67011:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8845,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67011:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8848,
+ "mutability": "mutable",
+ "name": "_reserveRatio",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8863,
+ "src": "67068:20:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8847,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "67068:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8850,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8863,
+ "src": "67122:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8849,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67122:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "66961:177:7"
+ },
+ "returnParameters": {
+ "id": 8854,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8853,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8863,
+ "src": "67192:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8852,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67192:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "67191:9:7"
+ },
+ "scope": 8977,
+ "src": "66935:355:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8884,
+ "nodeType": "Block",
+ "src": "67670:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8878,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8866,
+ "src": "67711:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8879,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8868,
+ "src": "67720:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8880,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8870,
+ "src": "67737:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8881,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8872,
+ "src": "67752:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8877,
+ "name": "liquidateReserveAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5626,
+ "src": "67688:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8882,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "67688:72:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8876,
+ "id": 8883,
+ "nodeType": "Return",
+ "src": "67681:79:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8864,
+ "nodeType": "StructuredDocumentation",
+ "src": "67298:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "abfd231d",
+ "id": 8885,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "calculateLiquidateReturn",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8873,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8866,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8885,
+ "src": "67398:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8865,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67398:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8868,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8885,
+ "src": "67454:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8867,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67454:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8870,
+ "mutability": "mutable",
+ "name": "_reserveRatio",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8885,
+ "src": "67518:20:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8869,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "67518:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8872,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8885,
+ "src": "67579:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8871,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67579:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "67397:198:7"
+ },
+ "returnParameters": {
+ "id": 8876,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8875,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8885,
+ "src": "67656:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8874,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67656:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "67655:9:7"
+ },
+ "scope": 8977,
+ "src": "67364:404:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8906,
+ "nodeType": "Block",
+ "src": "68089:97:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8900,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8888,
+ "src": "68128:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8901,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8890,
+ "src": "68137:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8902,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8892,
+ "src": "68154:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8903,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8894,
+ "src": "68170:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8899,
+ "name": "purchaseTargetAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5085,
+ "src": "68107:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8904,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "68107:71:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8898,
+ "id": 8905,
+ "nodeType": "Return",
+ "src": "68100:78:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8886,
+ "nodeType": "StructuredDocumentation",
+ "src": "67776:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "48d73fed",
+ "id": 8907,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "purchaseRate",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8895,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8888,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8907,
+ "src": "67864:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8887,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67864:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8890,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8907,
+ "src": "67908:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8889,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "67908:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8892,
+ "mutability": "mutable",
+ "name": "_reserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8907,
+ "src": "67960:21:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8891,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "67960:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8894,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8907,
+ "src": "68010:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8893,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68010:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "67863:163:7"
+ },
+ "returnParameters": {
+ "id": 8898,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8897,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8907,
+ "src": "68075:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8896,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68075:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "68074:9:7"
+ },
+ "scope": 8977,
+ "src": "67842:344:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8928,
+ "nodeType": "Block",
+ "src": "68487:93:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8922,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8910,
+ "src": "68522:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8923,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8912,
+ "src": "68531:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8924,
+ "name": "_reserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8914,
+ "src": "68548:14:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8925,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8916,
+ "src": "68564:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8921,
+ "name": "saleTargetAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5199,
+ "src": "68505:16:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8926,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "68505:67:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8920,
+ "id": 8927,
+ "nodeType": "Return",
+ "src": "68498:74:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8908,
+ "nodeType": "StructuredDocumentation",
+ "src": "68194:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "f732f1c9",
+ "id": 8929,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "saleRate",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8917,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8910,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8929,
+ "src": "68278:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8909,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68278:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8912,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8929,
+ "src": "68318:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8911,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68318:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8914,
+ "mutability": "mutable",
+ "name": "_reserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8929,
+ "src": "68366:21:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8913,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "68366:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8916,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8929,
+ "src": "68412:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8915,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68412:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "68277:151:7"
+ },
+ "returnParameters": {
+ "id": 8920,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8919,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8929,
+ "src": "68473:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8918,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68473:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "68472:9:7"
+ },
+ "scope": 8977,
+ "src": "68260:320:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8953,
+ "nodeType": "Block",
+ "src": "69007:149:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8946,
+ "name": "_sourceReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8932,
+ "src": "69050:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8947,
+ "name": "_sourceReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8934,
+ "src": "69073:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8948,
+ "name": "_targetReserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8936,
+ "src": "69095:21:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8949,
+ "name": "_targetReserveWeight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8938,
+ "src": "69118:20:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8950,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8940,
+ "src": "69140:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8945,
+ "name": "crossReserveTargetAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5305,
+ "src": "69025:24:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint32_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint32,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8951,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "69025:123:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8944,
+ "id": 8952,
+ "nodeType": "Return",
+ "src": "69018:130:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8930,
+ "nodeType": "StructuredDocumentation",
+ "src": "68588:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "9d114108",
+ "id": 8954,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "crossReserveRate",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8941,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8932,
+ "mutability": "mutable",
+ "name": "_sourceReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8954,
+ "src": "68680:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8931,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68680:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8934,
+ "mutability": "mutable",
+ "name": "_sourceReserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8954,
+ "src": "68742:27:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8933,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "68742:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8936,
+ "mutability": "mutable",
+ "name": "_targetReserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8954,
+ "src": "68802:29:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8935,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68802:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8938,
+ "mutability": "mutable",
+ "name": "_targetReserveWeight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8954,
+ "src": "68864:27:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8937,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "68864:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8940,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8954,
+ "src": "68924:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8939,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68924:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "68679:261:7"
+ },
+ "returnParameters": {
+ "id": 8944,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8943,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8954,
+ "src": "68993:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8942,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "68993:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "68992:9:7"
+ },
+ "scope": 8977,
+ "src": "68654:502:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 8975,
+ "nodeType": "Block",
+ "src": "69481:98:7",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 8969,
+ "name": "_supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8957,
+ "src": "69522:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8970,
+ "name": "_reserveBalance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8959,
+ "src": "69531:15:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8971,
+ "name": "_reserveRatio",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8961,
+ "src": "69548:13:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 8972,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 8963,
+ "src": "69563:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 8968,
+ "name": "liquidateReserveAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 5626,
+ "src": "69499:22:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view returns (uint256)"
+ }
+ },
+ "id": 8973,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "69499:72:7",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 8967,
+ "id": 8974,
+ "nodeType": "Return",
+ "src": "69492:79:7"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 8955,
+ "nodeType": "StructuredDocumentation",
+ "src": "69164:60:7",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "35b49af4",
+ "id": 8976,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "liquidateRate",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 8964,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8957,
+ "mutability": "mutable",
+ "name": "_supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8976,
+ "src": "69253:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8956,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "69253:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8959,
+ "mutability": "mutable",
+ "name": "_reserveBalance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8976,
+ "src": "69298:23:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8958,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "69298:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8961,
+ "mutability": "mutable",
+ "name": "_reserveRatio",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8976,
+ "src": "69351:20:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 8960,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "69351:6:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 8963,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8976,
+ "src": "69401:15:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8962,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "69401:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "69252:165:7"
+ },
+ "returnParameters": {
+ "id": 8967,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 8966,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 8976,
+ "src": "69467:7:7",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 8965,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "69467:7:7",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "69466:9:7"
+ },
+ "scope": 8977,
+ "src": "69230:349:7",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ }
+ ],
+ "scope": 8978,
+ "src": "157:69425:7"
+ }
+ ],
+ "src": "52:69532:7"
+ },
+ "compiler": {
+ "name": "solc",
+ "version": "0.6.12+commit.27d51765.Emscripten.clang"
+ },
+ "networks": {
+ "42": {
+ "events": {},
+ "links": {},
+ "address": "0xbc11EDec16f60B0B606921F88053C28f470E32d6",
+ "transactionHash": "0x24d52552794c7a4649d4b881db31094fc3c1fbbaf4718c04c9d4486304870b2c"
+ },
+ "8995": {
+ "events": {},
+ "links": {},
+ "address": "0xbc11EDec16f60B0B606921F88053C28f470E32d6",
+ "transactionHash": "0x24d52552794c7a4649d4b881db31094fc3c1fbbaf4718c04c9d4486304870b2c"
+ },
+ "1604964387852": {
+ "events": {},
+ "links": {},
+ "address": "0x2F8759fB1CF8Bbe0D1532B54c2143de2eF4BFC63",
+ "transactionHash": "0xabfbcd956a045c4ea82fbecbbde793829dbd8eda8433e34af02be26f95af0208"
+ },
+ "1604964469407": {
+ "events": {},
+ "links": {},
+ "address": "0xD44121A85018De957506F96B17a2A7719b16E6e0",
+ "transactionHash": "0x383e2d0b5371324bf0f040bdf53c3c2f6172b81c7d1a322c5ae8fb310b4ccd39"
+ },
+ "1604965528035": {
+ "events": {},
+ "links": {},
+ "address": "0xb242387159344b8620f9E7Affc284cb48EFB7c21",
+ "transactionHash": "0x3d19fbd65df5ffe30555f5164014dafca1aa48b52a9540094a3d87f0995b8cbc"
+ },
+ "1604965645554": {
+ "events": {},
+ "links": {},
+ "address": "0xD6037d8eFbE3618035E96d776754F1090F5273Fc",
+ "transactionHash": "0x3bc51eeb718827268d161f6689a57de296d05538fc2fc066b0a93f1fe0539101"
+ },
+ "1604965679541": {
+ "events": {},
+ "links": {},
+ "address": "0x8a2e520650DFC6A80f5891FBe928FA24Eb159772",
+ "transactionHash": "0xfc6563310e8c4fa7363b7127659cd66c376ab87682becda453b8cf37e93d9b69"
+ },
+ "1604965719492": {
+ "events": {},
+ "links": {},
+ "address": "0xbF5918e320aeF4FCE0a91f352F1Cbcd2Ed1c08D1",
+ "transactionHash": "0x047670bde378079fcb6cf649b53e1f86125380aa3f7b82ac04323a06617544ba"
+ },
+ "1604965760834": {
+ "events": {},
+ "links": {},
+ "address": "0x81Dd8B82b16D4552F222eE0B985DFa077e7B97CA",
+ "transactionHash": "0x7fc6bf0c25fd0dea62b704f018498d6a91ae9f8f4cacf4c47fab2b103a35d679"
+ }
+ },
+ "schemaVersion": "3.2.3",
+ "updatedAt": "2020-11-10T14:20:41.944Z",
+ "networkType": "ethereum",
+ "devdoc": {
+ "kind": "dev",
+ "methods": {
+ "balancedWeights(uint256,uint256,uint256,uint256,uint256)": {
+ "details": "The arbitrage incentive is to convert to the point where the on-chain price is equal to the off-chain price. We want this operation to also impact the primary reserve balance becoming equal to the primary reserve staked balance. In other words, we want the arbitrager to convert the difference between the reserve balance and the reserve staked balance. Formula input: - let t denote the primary reserve token staked balance - let s denote the primary reserve token balance - let r denote the secondary reserve token balance - let q denote the numerator of the rate between the tokens - let p denote the denominator of the rate between the tokens Where p primary tokens are equal to q secondary tokens Formula output: - compute x = W(t / r * q / p * log(s / t)) / log(s / t) - return x / (1 + x) as the weight of the primary reserve token - return 1 / (1 + x) as the weight of the secondary reserve token Where W is the Lambert W Function If the rate-provider provides the rates for a common unit, for example: - P = 2 ==> 2 primary reserve tokens = 1 ether - Q = 3 ==> 3 secondary reserve tokens = 1 ether Then you can simply use p = P and q = Q If the rate-provider provides the rates for a single unit, for example: - P = 2 ==> 1 primary reserve token = 2 ethers - Q = 3 ==> 1 secondary reserve token = 3 ethers Then you can simply use p = Q and q = P",
+ "params": {
+ "_primaryReserveBalance": "the primary reserve token balance",
+ "_primaryReserveStakedBalance": "the primary reserve token staked balance",
+ "_reserveRateDenominator": "the denominator of the rate between the tokens Note that `numerator / denominator` should represent the amount of secondary tokens equal to one primary token",
+ "_reserveRateNumerator": "the numerator of the rate between the tokens",
+ "_secondaryReserveBalance": "the secondary reserve token balance"
+ },
+ "returns": {
+ "_0": "the weight of the primary reserve token and the weight of the secondary reserve token, both in ppm (0-1000000)"
+ }
+ },
+ "calculateCrossConnectorReturn(uint256,uint32,uint256,uint32,uint256)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "calculateCrossReserveReturn(uint256,uint32,uint256,uint32,uint256)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "calculateFundCost(uint256,uint256,uint32,uint256)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "calculateLiquidateReturn(uint256,uint256,uint32,uint256)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "calculatePurchaseReturn(uint256,uint256,uint32,uint256)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "calculateSaleReturn(uint256,uint256,uint32,uint256)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "crossReserveRate(uint256,uint32,uint256,uint32,uint256)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "crossReserveTargetAmount(uint256,uint32,uint256,uint32,uint256)": {
+ "details": "given two reserve balances/weights and a sell amount (in the first reserve token), calculates the target amount for a conversion from the source reserve token to the target reserve token Formula: return = _targetReserveBalance * (1 - (_sourceReserveBalance / (_sourceReserveBalance + _amount)) ^ (_sourceReserveWeight / _targetReserveWeight))",
+ "params": {
+ "_amount": "source reserve amount",
+ "_sourceReserveBalance": "source reserve balance",
+ "_sourceReserveWeight": "source reserve weight, represented in ppm (1-1000000)",
+ "_targetReserveBalance": "target reserve balance",
+ "_targetReserveWeight": "target reserve weight, represented in ppm (1-1000000)"
+ },
+ "returns": {
+ "_0": "target reserve amount"
+ }
+ },
+ "fundCost(uint256,uint256,uint32,uint256)": {
+ "details": "given a smart token supply, reserve balance, reserve ratio and an amount of requested smart tokens, calculates the amount of reserve tokens required for purchasing the given amount of smart tokens Formula: return = _reserveBalance * (((_supply + _amount) / _supply) ^ (MAX_WEIGHT / _reserveRatio) - 1)",
+ "params": {
+ "_amount": "requested amount of smart tokens",
+ "_reserveBalance": "reserve balance",
+ "_reserveRatio": "reserve ratio, represented in ppm (2-2000000)",
+ "_supply": "smart token supply"
+ },
+ "returns": {
+ "_0": "reserve token amount"
+ }
+ },
+ "fundSupplyAmount(uint256,uint256,uint32,uint256)": {
+ "details": "given a smart token supply, reserve balance, reserve ratio and an amount of reserve tokens to fund with, calculates the amount of smart tokens received for purchasing with the given amount of reserve tokens Formula: return = _supply * ((_amount / _reserveBalance + 1) ^ (_reserveRatio / MAX_WEIGHT) - 1)",
+ "params": {
+ "_amount": "amount of reserve tokens to fund with",
+ "_reserveBalance": "reserve balance",
+ "_reserveRatio": "reserve ratio, represented in ppm (2-2000000)",
+ "_supply": "smart token supply"
+ },
+ "returns": {
+ "_0": "smart token amount"
+ }
+ },
+ "init()": {
+ "details": "should be executed after construction (too large for the constructor)"
+ },
+ "liquidateRate(uint256,uint256,uint32,uint256)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "liquidateReserveAmount(uint256,uint256,uint32,uint256)": {
+ "details": "given a smart token supply, reserve balance, reserve ratio and an amount of smart tokens to liquidate, calculates the amount of reserve tokens received for selling the given amount of smart tokens Formula: return = _reserveBalance * (1 - ((_supply - _amount) / _supply) ^ (MAX_WEIGHT / _reserveRatio))",
+ "params": {
+ "_amount": "amount of smart tokens to liquidate",
+ "_reserveBalance": "reserve balance",
+ "_reserveRatio": "reserve ratio, represented in ppm (2-2000000)",
+ "_supply": "smart token supply"
+ },
+ "returns": {
+ "_0": "reserve token amount"
+ }
+ },
+ "purchaseRate(uint256,uint256,uint32,uint256)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "purchaseTargetAmount(uint256,uint256,uint32,uint256)": {
+ "details": "given a token supply, reserve balance, weight and a deposit amount (in the reserve token), calculates the target amount for a given conversion (in the main token) Formula: return = _supply * ((1 + _amount / _reserveBalance) ^ (_reserveWeight / 1000000) - 1)",
+ "params": {
+ "_amount": "amount of reserve tokens to get the target amount for",
+ "_reserveBalance": "reserve balance",
+ "_reserveWeight": "reserve weight, represented in ppm (1-1000000)",
+ "_supply": "smart token supply"
+ },
+ "returns": {
+ "_0": "smart token amount"
+ }
+ },
+ "saleRate(uint256,uint256,uint32,uint256)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "saleTargetAmount(uint256,uint256,uint32,uint256)": {
+ "details": "given a token supply, reserve balance, weight and a sell amount (in the main token), calculates the target amount for a given conversion (in the reserve token) Formula: return = _reserveBalance * (1 - (1 - _amount / _supply) ^ (1000000 / _reserveWeight))",
+ "params": {
+ "_amount": "amount of smart tokens to get the target amount for",
+ "_reserveBalance": "reserve balance",
+ "_reserveWeight": "reserve weight, represented in ppm (1-1000000)",
+ "_supply": "smart token supply"
+ },
+ "returns": {
+ "_0": "reserve token amount"
+ }
+ }
+ },
+ "version": 1
+ },
+ "userdoc": {
+ "kind": "user",
+ "methods": {},
+ "version": 1
+ }
+}
\ No newline at end of file
diff --git a/apps/cic-eth/tests/testdata/bancor/BancorNetwork.json b/apps/cic-eth/tests/testdata/bancor/BancorNetwork.json
new file mode 100644
index 00000000..679d79ac
--- /dev/null
+++ b/apps/cic-eth/tests/testdata/bancor/BancorNetwork.json
@@ -0,0 +1,56968 @@
+{
+ "contractName": "BancorNetwork",
+ "abi": [
+ {
+ "inputs": [
+ {
+ "internalType": "contract IContractRegistry",
+ "name": "_registry",
+ "type": "address"
+ }
+ ],
+ "stateMutability": "nonpayable",
+ "type": "constructor"
+ },
+ {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "contract IConverterAnchor",
+ "name": "_smartToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_fromToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_toToken",
+ "type": "address"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_fromAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_toAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "address",
+ "name": "_trader",
+ "type": "address"
+ }
+ ],
+ "name": "Conversion",
+ "type": "event"
+ },
+ {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_prevOwner",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_newOwner",
+ "type": "address"
+ }
+ ],
+ "name": "OwnerUpdate",
+ "type": "event"
+ },
+ {
+ "inputs": [],
+ "name": "acceptOwnership",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "contract IERC20Token",
+ "name": "",
+ "type": "address"
+ }
+ ],
+ "name": "etherTokens",
+ "outputs": [
+ {
+ "internalType": "bool",
+ "name": "",
+ "type": "bool"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [],
+ "name": "maxAffiliateFee",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [],
+ "name": "newOwner",
+ "outputs": [
+ {
+ "internalType": "address",
+ "name": "",
+ "type": "address"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [],
+ "name": "onlyOwnerCanUpdateRegistry",
+ "outputs": [
+ {
+ "internalType": "bool",
+ "name": "",
+ "type": "bool"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [],
+ "name": "owner",
+ "outputs": [
+ {
+ "internalType": "address",
+ "name": "",
+ "type": "address"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [],
+ "name": "prevRegistry",
+ "outputs": [
+ {
+ "internalType": "contract IContractRegistry",
+ "name": "",
+ "type": "address"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [],
+ "name": "registry",
+ "outputs": [
+ {
+ "internalType": "contract IContractRegistry",
+ "name": "",
+ "type": "address"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [],
+ "name": "restoreRegistry",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "bool",
+ "name": "_onlyOwnerCanUpdateRegistry",
+ "type": "bool"
+ }
+ ],
+ "name": "restrictRegistryUpdate",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address",
+ "name": "_newOwner",
+ "type": "address"
+ }
+ ],
+ "name": "transferOwnership",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "updateRegistry",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "contract IERC20Token",
+ "name": "_token",
+ "type": "address"
+ },
+ {
+ "internalType": "address",
+ "name": "_to",
+ "type": "address"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "withdrawTokens",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_maxAffiliateFee",
+ "type": "uint256"
+ }
+ ],
+ "name": "setMaxAffiliateFee",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "contract IEtherToken",
+ "name": "_token",
+ "type": "address"
+ },
+ {
+ "internalType": "bool",
+ "name": "_register",
+ "type": "bool"
+ }
+ ],
+ "name": "registerEtherToken",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "contract IERC20Token",
+ "name": "_sourceToken",
+ "type": "address"
+ },
+ {
+ "internalType": "contract IERC20Token",
+ "name": "_targetToken",
+ "type": "address"
+ }
+ ],
+ "name": "conversionPath",
+ "outputs": [
+ {
+ "internalType": "address[]",
+ "name": "",
+ "type": "address[]"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address[]",
+ "name": "_path",
+ "type": "address[]"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "rateByPath",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address[]",
+ "name": "_path",
+ "type": "address[]"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_minReturn",
+ "type": "uint256"
+ },
+ {
+ "internalType": "address payable",
+ "name": "_beneficiary",
+ "type": "address"
+ },
+ {
+ "internalType": "address",
+ "name": "_affiliateAccount",
+ "type": "address"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_affiliateFee",
+ "type": "uint256"
+ }
+ ],
+ "name": "convertByPath",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "payable",
+ "type": "function",
+ "payable": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address[]",
+ "name": "_path",
+ "type": "address[]"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_minReturn",
+ "type": "uint256"
+ },
+ {
+ "internalType": "bytes32",
+ "name": "_targetBlockchain",
+ "type": "bytes32"
+ },
+ {
+ "internalType": "bytes32",
+ "name": "_targetAccount",
+ "type": "bytes32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_conversionId",
+ "type": "uint256"
+ }
+ ],
+ "name": "xConvert",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "payable",
+ "type": "function",
+ "payable": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address[]",
+ "name": "_path",
+ "type": "address[]"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_minReturn",
+ "type": "uint256"
+ },
+ {
+ "internalType": "bytes32",
+ "name": "_targetBlockchain",
+ "type": "bytes32"
+ },
+ {
+ "internalType": "bytes32",
+ "name": "_targetAccount",
+ "type": "bytes32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_conversionId",
+ "type": "uint256"
+ },
+ {
+ "internalType": "address",
+ "name": "_affiliateAccount",
+ "type": "address"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_affiliateFee",
+ "type": "uint256"
+ }
+ ],
+ "name": "xConvert2",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "payable",
+ "type": "function",
+ "payable": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address[]",
+ "name": "_path",
+ "type": "address[]"
+ },
+ {
+ "internalType": "contract IBancorX",
+ "name": "_bancorX",
+ "type": "address"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_conversionId",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_minReturn",
+ "type": "uint256"
+ },
+ {
+ "internalType": "address payable",
+ "name": "_beneficiary",
+ "type": "address"
+ }
+ ],
+ "name": "completeXConversion",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address[]",
+ "name": "_path",
+ "type": "address[]"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "getReturnByPath",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function",
+ "constant": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address[]",
+ "name": "_path",
+ "type": "address[]"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_minReturn",
+ "type": "uint256"
+ }
+ ],
+ "name": "convert",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "payable",
+ "type": "function",
+ "payable": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address[]",
+ "name": "_path",
+ "type": "address[]"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_minReturn",
+ "type": "uint256"
+ },
+ {
+ "internalType": "address",
+ "name": "_affiliateAccount",
+ "type": "address"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_affiliateFee",
+ "type": "uint256"
+ }
+ ],
+ "name": "convert2",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "payable",
+ "type": "function",
+ "payable": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address[]",
+ "name": "_path",
+ "type": "address[]"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_minReturn",
+ "type": "uint256"
+ },
+ {
+ "internalType": "address payable",
+ "name": "_beneficiary",
+ "type": "address"
+ }
+ ],
+ "name": "convertFor",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "payable",
+ "type": "function",
+ "payable": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address[]",
+ "name": "_path",
+ "type": "address[]"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_minReturn",
+ "type": "uint256"
+ },
+ {
+ "internalType": "address payable",
+ "name": "_beneficiary",
+ "type": "address"
+ },
+ {
+ "internalType": "address",
+ "name": "_affiliateAccount",
+ "type": "address"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_affiliateFee",
+ "type": "uint256"
+ }
+ ],
+ "name": "convertFor2",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "payable",
+ "type": "function",
+ "payable": true
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address[]",
+ "name": "_path",
+ "type": "address[]"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_minReturn",
+ "type": "uint256"
+ }
+ ],
+ "name": "claimAndConvert",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address[]",
+ "name": "_path",
+ "type": "address[]"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_minReturn",
+ "type": "uint256"
+ },
+ {
+ "internalType": "address",
+ "name": "_affiliateAccount",
+ "type": "address"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_affiliateFee",
+ "type": "uint256"
+ }
+ ],
+ "name": "claimAndConvert2",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address[]",
+ "name": "_path",
+ "type": "address[]"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_minReturn",
+ "type": "uint256"
+ },
+ {
+ "internalType": "address payable",
+ "name": "_beneficiary",
+ "type": "address"
+ }
+ ],
+ "name": "claimAndConvertFor",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address[]",
+ "name": "_path",
+ "type": "address[]"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_minReturn",
+ "type": "uint256"
+ },
+ {
+ "internalType": "address payable",
+ "name": "_beneficiary",
+ "type": "address"
+ },
+ {
+ "internalType": "address",
+ "name": "_affiliateAccount",
+ "type": "address"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_affiliateFee",
+ "type": "uint256"
+ }
+ ],
+ "name": "claimAndConvertFor2",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ }
+ ],
+ "metadata": "{\"compiler\":{\"version\":\"0.6.12+commit.27d51765\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"contract IContractRegistry\",\"name\":\"_registry\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"contract IConverterAnchor\",\"name\":\"_smartToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"contract IERC20Token\",\"name\":\"_fromToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"contract IERC20Token\",\"name\":\"_toToken\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"_fromAmount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"_toAmount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"_trader\",\"type\":\"address\"}],\"name\":\"Conversion\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"_prevOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"_newOwner\",\"type\":\"address\"}],\"name\":\"OwnerUpdate\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_path\",\"type\":\"address[]\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_minReturn\",\"type\":\"uint256\"}],\"name\":\"claimAndConvert\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_path\",\"type\":\"address[]\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_minReturn\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"_affiliateAccount\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_affiliateFee\",\"type\":\"uint256\"}],\"name\":\"claimAndConvert2\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_path\",\"type\":\"address[]\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_minReturn\",\"type\":\"uint256\"},{\"internalType\":\"address payable\",\"name\":\"_beneficiary\",\"type\":\"address\"}],\"name\":\"claimAndConvertFor\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_path\",\"type\":\"address[]\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_minReturn\",\"type\":\"uint256\"},{\"internalType\":\"address payable\",\"name\":\"_beneficiary\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_affiliateAccount\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_affiliateFee\",\"type\":\"uint256\"}],\"name\":\"claimAndConvertFor2\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_path\",\"type\":\"address[]\"},{\"internalType\":\"contract IBancorX\",\"name\":\"_bancorX\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_conversionId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_minReturn\",\"type\":\"uint256\"},{\"internalType\":\"address payable\",\"name\":\"_beneficiary\",\"type\":\"address\"}],\"name\":\"completeXConversion\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contract IERC20Token\",\"name\":\"_sourceToken\",\"type\":\"address\"},{\"internalType\":\"contract IERC20Token\",\"name\":\"_targetToken\",\"type\":\"address\"}],\"name\":\"conversionPath\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_path\",\"type\":\"address[]\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_minReturn\",\"type\":\"uint256\"}],\"name\":\"convert\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_path\",\"type\":\"address[]\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_minReturn\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"_affiliateAccount\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_affiliateFee\",\"type\":\"uint256\"}],\"name\":\"convert2\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_path\",\"type\":\"address[]\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_minReturn\",\"type\":\"uint256\"},{\"internalType\":\"address payable\",\"name\":\"_beneficiary\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_affiliateAccount\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_affiliateFee\",\"type\":\"uint256\"}],\"name\":\"convertByPath\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_path\",\"type\":\"address[]\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_minReturn\",\"type\":\"uint256\"},{\"internalType\":\"address payable\",\"name\":\"_beneficiary\",\"type\":\"address\"}],\"name\":\"convertFor\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_path\",\"type\":\"address[]\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_minReturn\",\"type\":\"uint256\"},{\"internalType\":\"address payable\",\"name\":\"_beneficiary\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_affiliateAccount\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_affiliateFee\",\"type\":\"uint256\"}],\"name\":\"convertFor2\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contract IERC20Token\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"etherTokens\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_path\",\"type\":\"address[]\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"getReturnByPath\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"maxAffiliateFee\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"newOwner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"onlyOwnerCanUpdateRegistry\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"prevRegistry\",\"outputs\":[{\"internalType\":\"contract IContractRegistry\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_path\",\"type\":\"address[]\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"rateByPath\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contract IEtherToken\",\"name\":\"_token\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"_register\",\"type\":\"bool\"}],\"name\":\"registerEtherToken\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contract IContractRegistry\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"restoreRegistry\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"_onlyOwnerCanUpdateRegistry\",\"type\":\"bool\"}],\"name\":\"restrictRegistryUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_maxAffiliateFee\",\"type\":\"uint256\"}],\"name\":\"setMaxAffiliateFee\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateRegistry\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contract IERC20Token\",\"name\":\"_token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"withdrawTokens\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_path\",\"type\":\"address[]\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_minReturn\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"_targetBlockchain\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"_targetAccount\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_conversionId\",\"type\":\"uint256\"}],\"name\":\"xConvert\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_path\",\"type\":\"address[]\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_minReturn\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"_targetBlockchain\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"_targetAccount\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_conversionId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"_affiliateAccount\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_affiliateFee\",\"type\":\"uint256\"}],\"name\":\"xConvert2\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"payable\",\"type\":\"function\"}],\"devdoc\":{\"details\":\"The BancorNetwork contract is the main entry point for Bancor token conversions. It also allows for the conversion of any token in the Bancor Network to any other token in a single transaction by providing a conversion path. A note on Conversion Path: Conversion path is a data structure that is used when converting a token to another token in the Bancor Network, when the conversion cannot necessarily be done by a single converter and might require multiple 'hops'. The path defines which converters should be used and what kind of conversion should be done in each step. The path format doesn't include complex structure; instead, it is represented by a single array in which each 'hop' is represented by a 2-tuple - converter anchor & target token. In addition, the first element is always the source token. The converter anchor is only used as a pointer to a converter (since converter addresses are more likely to change as opposed to anchor addresses). Format: [source token, converter anchor, target token, converter anchor, target token...]\",\"events\":{\"Conversion(address,address,address,uint256,uint256,address)\":{\"details\":\"triggered when a conversion between two tokens occurs\",\"params\":{\"_fromAmount\":\"amount converted, in the source token\",\"_fromToken\":\"source ERC20 token\",\"_smartToken\":\"anchor governed by the converter\",\"_toAmount\":\"amount returned, minus conversion fee\",\"_toToken\":\"target ERC20 token\",\"_trader\":\"wallet that initiated the trade\"}}},\"kind\":\"dev\",\"methods\":{\"acceptOwnership()\":{\"details\":\"used by a new owner to accept an ownership transfer\"},\"claimAndConvert(address[],uint256,uint256)\":{\"details\":\"deprecated, backward compatibility\"},\"claimAndConvert2(address[],uint256,uint256,address,uint256)\":{\"details\":\"deprecated, backward compatibility\"},\"claimAndConvertFor(address[],uint256,uint256,address)\":{\"details\":\"deprecated, backward compatibility\"},\"claimAndConvertFor2(address[],uint256,uint256,address,address,uint256)\":{\"details\":\"deprecated, backward compatibility\"},\"completeXConversion(address[],address,uint256,uint256,address)\":{\"details\":\"allows a user to convert a token that was sent from another blockchain into any other token on the BancorNetwork ideally this transaction is created before the previous conversion is even complete, so so the input amount isn't known at that point - the amount is actually take from the BancorX contract directly by specifying the conversion id\",\"params\":{\"_bancorX\":\"address of the BancorX contract for the source token\",\"_beneficiary\":\"wallet to receive the conversion result\",\"_conversionId\":\"pre-determined unique (if non zero) id which refers to this conversion\",\"_minReturn\":\"if the conversion results in an amount smaller than the minimum return - it is cancelled, must be nonzero\",\"_path\":\"conversion path\"},\"returns\":{\"_0\":\"amount of tokens received from the conversion\"}},\"constructor\":{\"details\":\"initializes a new BancorNetwork instance\",\"params\":{\"_registry\":\"address of a contract registry contract\"}},\"conversionPath(address,address)\":{\"details\":\"returns the conversion path between two tokens in the network note that this method is quite expensive in terms of gas and should generally be called off-chain\",\"params\":{\"_sourceToken\":\"source token address\",\"_targetToken\":\"target token address\"},\"returns\":{\"_0\":\"conversion path between the two tokens\"}},\"convert(address[],uint256,uint256)\":{\"details\":\"deprecated, backward compatibility\"},\"convert2(address[],uint256,uint256,address,uint256)\":{\"details\":\"deprecated, backward compatibility\"},\"convertByPath(address[],uint256,uint256,address,address,uint256)\":{\"details\":\"converts the token to any other token in the bancor network by following a predefined conversion path and transfers the result tokens to a target account affiliate account/fee can also be passed in to receive a conversion fee (on top of the liquidity provider fees) note that the network should already have been given allowance of the source token (if not ETH)\",\"params\":{\"_affiliateAccount\":\"wallet address to receive the affiliate fee or 0x0 to disable affiliate fee\",\"_affiliateFee\":\"affiliate fee in PPM or 0 to disable affiliate fee\",\"_amount\":\"amount to convert from, in the source token\",\"_beneficiary\":\"account that will receive the conversion result or 0x0 to send the result to the sender account\",\"_minReturn\":\"if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero\",\"_path\":\"conversion path, see conversion path format above\"},\"returns\":{\"_0\":\"amount of tokens received from the conversion\"}},\"convertFor(address[],uint256,uint256,address)\":{\"details\":\"deprecated, backward compatibility\"},\"convertFor2(address[],uint256,uint256,address,address,uint256)\":{\"details\":\"deprecated, backward compatibility\"},\"getReturnByPath(address[],uint256)\":{\"details\":\"deprecated, backward compatibility\"},\"rateByPath(address[],uint256)\":{\"details\":\"returns the expected target amount of converting a given amount on a given path note that there is no support for circular paths\",\"params\":{\"_amount\":\"amount of _path[0] tokens received from the sender\",\"_path\":\"conversion path (see conversion path format above)\"},\"returns\":{\"_0\":\"expected target amount\"}},\"registerEtherToken(address,bool)\":{\"details\":\"allows the owner to register/unregister ether tokens\",\"params\":{\"_register\":\"true to register, false to unregister\",\"_token\":\"ether token contract address\"}},\"restoreRegistry()\":{\"details\":\"restores the previous contract-registry\"},\"restrictRegistryUpdate(bool)\":{\"details\":\"restricts the permission to update the contract-registry\",\"params\":{\"_onlyOwnerCanUpdateRegistry\":\"indicates whether or not permission is restricted to owner only\"}},\"setMaxAffiliateFee(uint256)\":{\"details\":\"allows the owner to update the maximum affiliate-fee\",\"params\":{\"_maxAffiliateFee\":\"maximum affiliate-fee\"}},\"transferOwnership(address)\":{\"details\":\"allows transferring the contract ownership the new owner still needs to accept the transfer can only be called by the contract owner\",\"params\":{\"_newOwner\":\"new contract owner\"}},\"updateRegistry()\":{\"details\":\"updates to the new contract-registry\"},\"withdrawTokens(address,address,uint256)\":{\"details\":\"withdraws tokens held by the contract and sends them to an account can only be called by the owner\",\"params\":{\"_amount\":\"amount to withdraw\",\"_to\":\"account to receive the new amount\",\"_token\":\"ERC20 token contract address\"}},\"xConvert(address[],uint256,uint256,bytes32,bytes32,uint256)\":{\"details\":\"converts any other token to BNT in the bancor network by following a predefined conversion path and transfers the result to an account on a different blockchain note that the network should already have been given allowance of the source token (if not ETH)\",\"params\":{\"_amount\":\"amount to convert from, in the source token\",\"_conversionId\":\"pre-determined unique (if non zero) id which refers to this transaction\",\"_minReturn\":\"if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero\",\"_path\":\"conversion path, see conversion path format above\",\"_targetAccount\":\"address/account on the target blockchain to send the BNT to\",\"_targetBlockchain\":\"blockchain BNT will be issued on\"},\"returns\":{\"_0\":\"the amount of BNT received from this conversion\"}},\"xConvert2(address[],uint256,uint256,bytes32,bytes32,uint256,address,uint256)\":{\"details\":\"converts any other token to BNT in the bancor network by following a predefined conversion path and transfers the result to an account on a different blockchain note that the network should already have been given allowance of the source token (if not ETH)\",\"params\":{\"_affiliateAccount\":\"affiliate account\",\"_affiliateFee\":\"affiliate fee in PPM\",\"_amount\":\"amount to convert from, in the source token\",\"_conversionId\":\"pre-determined unique (if non zero) id which refers to this transaction\",\"_minReturn\":\"if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero\",\"_path\":\"conversion path, see conversion path format above\",\"_targetAccount\":\"address/account on the target blockchain to send the BNT to\",\"_targetBlockchain\":\"blockchain BNT will be issued on\"},\"returns\":{\"_0\":\"the amount of BNT received from this conversion\"}}},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/BancorNetwork.sol\":\"BancorNetwork\"},\"evmVersion\":\"istanbul\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":200},\"remappings\":[]},\"sources\":{\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/BancorNetwork.sol\":{\"keccak256\":\"0xb1817f3d45dd66177f17cf45f1b660186ee35575222a11c9bc0e0d44b32846ea\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://ce648a9b8038bb11d1ed091a16aa831a973ff2896ae9aae6b34cb9a8d0e02b00\",\"dweb:/ipfs/QmQKqVVXV6dDBd8saigyEALeLwjG8nhqK8wLRqDGaKSDV6\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/IConversionPathFinder.sol\":{\"keccak256\":\"0x2d0f5b57bc448581a6e2296486ca618851138f40928049d75220623605915d7b\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://2182eb05da8442792a5f3f4d8cdb2cf0bf9e952ca02638f3880cc59d5fd6dcb6\",\"dweb:/ipfs/QmSH9uWh6zTQkcBgD7VGGSzYW9DjdBDkUZUZ6zhzPWPPDz\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/bancorx/interfaces/IBancorX.sol\":{\"keccak256\":\"0x65b5780d710159c7540078c38406c53db37a349fb468a0bf21bdc6262e497951\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://3df931a12770d10a22451326e38ae9d405d3e2716bdbdd6306b5e2361f6fe511\",\"dweb:/ipfs/QmcRBSaFLz516dAEqb8ZEiyx8ZTHZZ6rfxHn5roL2fHA3S\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IBancorFormula.sol\":{\"keccak256\":\"0xf30c95034af4c4ec6e8a859e90cf7a0bada29a805ede76e04644107a7c677c4e\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://b48070d4abf9c4a08c39e6c494fa9efd7389aa7f8b61b283c9ba02062b1c59b6\",\"dweb:/ipfs/Qme6U7SpspFPzMH2mTyKsXCnJEAgg1vX6NNFzuykbVSY5R\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IConverter.sol\":{\"keccak256\":\"0x18b0d73a3d5ee951ede1b3f840ed35b40570e34975703079a4451555f4dd089b\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://1cd7263f1ef60793e3929509150420037df9a1194c3d0f40bb2ff5516d6a373f\",\"dweb:/ipfs/QmNUbsZt2rzWPjStYycgz3vMbNP4VrAqZPRAK39QNqUoos\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IConverterAnchor.sol\":{\"keccak256\":\"0x9448cdbe90293fb5c1a0808b77af8754a1025b59c45f432eee01f659361a6115\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://1ef2bb2e1543c9324daf7f3fd086a57efb45b89f3d62b9d7a9fc78c138d24dbc\",\"dweb:/ipfs/QmVcXDib3K6xYJMBNxawmo4krJGiDfxb5oL64Lc3pi14XK\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/interfaces/IERC20Token.sol\":{\"keccak256\":\"0xe6f988c3156e88258474526a541d5a42b6a9adae98b04177a059d9f723bc82cd\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://9a6eb77a5b9ce70995a11a6e48ac3985a4c70896fe5fe04d46146ad7c1c83ea3\",\"dweb:/ipfs/QmYvGSveZFG51tghwkVuu6eK9Jy8frHpfLxHTMyvNZN461\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/interfaces/IEtherToken.sol\":{\"keccak256\":\"0x6ed324da616d70af0b21fa073b1e5329b430e38b470177633a69710eff3da893\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://44f94aa59c67de636423cbdef82efb7d8e0562e73dfc9049a48054156aebaf14\",\"dweb:/ipfs/Qmdn8KAP54s7X3J6TCoZPhCpS19aCQzFYZuFABugJ5JA5D\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/interfaces/ISmartToken.sol\":{\"keccak256\":\"0x5cfc15e7a23a9872059b0cea4d2ae902c3fc074a39e1c645036ce38ad47881ec\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://890ee09d24de5778e34c4c27d1377d83d378e8f4a13fcb94d5102f61d4749cce\",\"dweb:/ipfs/QmT89f61fmsUN1BVdebKxUc5VU7sitiP33LNk7TTtF18oj\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/ContractRegistryClient.sol\":{\"keccak256\":\"0x74caf88eff1cb113ad8277df9ba7933a6f1e0deea8fd1855157def3be833b859\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://c7793c9f245736cd8413bc8c4b5c40b67949cbee32289a16d29c83cf59396ad6\",\"dweb:/ipfs/QmWony7b1buUrGnE32gjLAnSwkBYMrJ68vUcCwDMmp3MbJ\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/Owned.sol\":{\"keccak256\":\"0x6ef69d9dcc80a8a36d5eb37783375cd5e4831c6d20c723fa6f6b6a06c0aeb53d\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://5a5d087e2c5b47739615ef22e1f29749de44b43c9a37cfae32b3dfc498a258c4\",\"dweb:/ipfs/Qmd1mXKEQbmBxqHk326LGVzNoayXsam8gZNecknnYpBnyh\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/ReentrancyGuard.sol\":{\"keccak256\":\"0x5ea87c10dd6e7e79212da712eb5f079c03361e6c96e299a4ffd9aaee8d6a3899\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://882aac64a791df35a942480e6ce611d1acb399af4ac0c4ef0288965c3785bf50\",\"dweb:/ipfs/QmeWeYYFh5HZAzJ1SzPHoTcPvZrE4NPUVfmjvH9Q3m36Gg\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/SafeMath.sol\":{\"keccak256\":\"0x1ab7391a19ca8a3ad2f3c4a1074e080d4d76dfdb834637bdd0c1e6b6acdf28af\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://d6d8c99621ca884b72da2d84eddfec8ec8c5533915691d6eec94a07adf445608\",\"dweb:/ipfs/QmaXr6DN7VbfxfMn3PsTy7SAMgZVVXbdeaw11BsAjVL2x1\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/TokenHandler.sol\":{\"keccak256\":\"0xf65b87e3bf3343e368da67878c19d1a043a1025b10e9053d3562b53b4aa447fe\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://b85c5d96642c14c53b8d5062eecd4d27d3bdb457d1d0f130900763a75a512eb7\",\"dweb:/ipfs/QmUHtbqC1khqnRZXYn11Aykus4m5e9MVNUWqorxhpr5ipJ\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/TokenHolder.sol\":{\"keccak256\":\"0xac6bc102eff6c1bb8c1bb4466eab50322c7c101e2e33d577dd3035f106627577\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://9fdbda2d4509260ca3dd43654bdaea07ef18a5e04213ff16e38e3b4abad78a5f\",\"dweb:/ipfs/QmPb69rzX1DwDeEhhfzqQNS3U2bfGcFjXNaV5ffHsZHzfP\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/Utils.sol\":{\"keccak256\":\"0x073efa69fcd6b5e60f841b28b366d63b62ff48ab12a06ce3f5a7f41afd6ce885\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://e8b8ecb2d29197ca77f0ed98f728ace54e6edcfdf5cd1194ae22701607eaf608\",\"dweb:/ipfs/QmcsR6Q35Hurh3TrPkYAboicz9bQQoGCWmZLzUCDyhotH8\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/interfaces/IContractRegistry.sol\":{\"keccak256\":\"0x3551889a83738b621c29ed66f1ecb6a843cca4217e54c9357198559b9cc92259\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://231a59c8f2665adeda8c7e6930832409c9b991fd27ad84b3a24335e7bf269bbe\",\"dweb:/ipfs/QmeJJbn1EAUbZenruTEdJAnwUn3dxsVNeJvxPe81qKEGqL\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/interfaces/IOwned.sol\":{\"keccak256\":\"0xc60a9d197abc28c1906ed4d18b59caa0242db754a0e1f67af6e6277593530dae\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://a8c6f3e6525a81a5165ccbf04f73f6c389c14b74135d11a7b5f70b1c9bdac75c\",\"dweb:/ipfs/QmaPu4Z7yUPc9sMADmoTZVY6AnyDSYHtNNCx3mm4VkJwhP\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/interfaces/ITokenHolder.sol\":{\"keccak256\":\"0x9ccb8ab04d0bd874ba7aae5277e60f35c36918922649a0596bf3664ed257bfe2\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://b65e6db19cd244c9f3545695de5fd7573711c49fb306631ddbf0e1d2fa9fb589\",\"dweb:/ipfs/QmZeu5KYVMTbTx7h2BVUq52fpwL9Q44AUfzeVksucDohgf\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/interfaces/IWhitelist.sol\":{\"keccak256\":\"0x356ad553ceeaea04d7cb8f0d6a5663c47dfccb2bd82517348128f032416ee34a\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://9ea3bbb9945144ead2c1392351f2f9f7444af78569f2b95da2e68bb6b919db52\",\"dweb:/ipfs/QmPyUAk44Kj7nJB4tzYqeSXWHyYP51mRNynEmWra9m4eKS\"]}},\"version\":1}",
+ "bytecode": "0x60806040526003805460ff60a81b191690556175306004553480156200002457600080fd5b50604051620039ad380380620039ad833981810160405260208110156200004a57600080fd5b5051600080546001600160a01b0319163317905580806200006b81620000e6565b50600280546001600160a01b039092166001600160a01b03199283168117909155600380549092161790555073eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee60005260056020527fa1829a9003092132f585b6ccdd167c19fe9774dbdea4260287e8a8e8ca8185d7805460ff1916600117905562000145565b6001600160a01b03811662000142576040805162461bcd60e51b815260206004820152601360248201527f4552525f494e56414c49445f4144445245535300000000000000000000000000604482015290519081900360640190fd5b50565b61385880620001556000396000f3fe6080604052600436106101cd5760003560e01c80638da5cb5b116100f7578063c98fefed11610095578063e57738e511610064578063e57738e514610ca7578063f2fde38b14610cca578063f3898a9714610cfd578063f3bc7d2a14610d13576101cd565b8063c98fefed14610b23578063cb32564e14610b39578063d4ee1d9014610c07578063d734fa1914610c1c576101cd565b8063b4a176d3116100d1578063b4a176d3146108de578063b77d239b146108f3578063c52173de146109b8578063c7ba24bc14610a70576101cd565b80638da5cb5b14610742578063ab6214ce14610757578063b1e9932b1461081c576101cd565b80635d732ff21161016f5780637b1039991161013e5780637b1039991461057f5780637f9c0ecd146105945780638077ccf71461064457806389f9cc6114610677576101cd565b80635d732ff2146104e15780635e35359e146104f657806361cd756e1461053957806379ba50971461056a576101cd565b80632978c10e116101ab5780632978c10e146103045780632fe8a6ad146103e857806349d10b6414610411578063569706eb14610426576101cd565b8063024c7ec7146101d257806302ef521e146102005780630c8496cc1461023b575b600080fd5b3480156101de57600080fd5b506101fe600480360360208110156101f557600080fd5b50351515610d3d565b005b34801561020c57600080fd5b506101fe6004803603604081101561022357600080fd5b506001600160a01b0381351690602001351515610d63565b34801561024757600080fd5b506102eb6004803603604081101561025e57600080fd5b810190602081018135600160201b81111561027857600080fd5b82018360208201111561028a57600080fd5b803590602001918460208302840111600160201b831117156102ab57600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295505091359250610dac915050565b6040805192835260208301919091528051918290030190f35b34801561031057600080fd5b506103d6600480360360c081101561032757600080fd5b810190602081018135600160201b81111561034157600080fd5b82018360208201111561035357600080fd5b803590602001918460208302840111600160201b8311171561037457600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550508235935050506020810135906001600160a01b03604082013581169160608101359091169060800135610dc4565b60408051918252519081900360200190f35b3480156103f457600080fd5b506103fd610ddf565b604080519115158252519081900360200190f35b34801561041d57600080fd5b506101fe610def565b6103d6600480360360a081101561043c57600080fd5b810190602081018135600160201b81111561045657600080fd5b82018360208201111561046857600080fd5b803590602001918460208302840111600160201b8311171561048957600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550508235935050506020810135906001600160a01b036040820135169060600135610ff7565b3480156104ed57600080fd5b506103d6611012565b34801561050257600080fd5b506101fe6004803603606081101561051957600080fd5b506001600160a01b03813581169160208101359091169060400135611018565b34801561054557600080fd5b5061054e611051565b604080516001600160a01b039092168252519081900360200190f35b34801561057657600080fd5b506101fe611060565b34801561058b57600080fd5b5061054e611117565b3480156105a057600080fd5b506103d6600480360360408110156105b757600080fd5b810190602081018135600160201b8111156105d157600080fd5b8201836020820111156105e357600080fd5b803590602001918460208302840111600160201b8311171561060457600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295505091359250611126915050565b34801561065057600080fd5b506103fd6004803603602081101561066757600080fd5b50356001600160a01b0316611843565b34801561068357600080fd5b506103d6600480360360a081101561069a57600080fd5b810190602081018135600160201b8111156106b457600080fd5b8201836020820111156106c657600080fd5b803590602001918460208302840111600160201b831117156106e757600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550506001600160a01b038335811694506020840135936040810135935060600135169050611858565b34801561074e57600080fd5b5061054e6119cf565b6103d6600480360360c081101561076d57600080fd5b810190602081018135600160201b81111561078757600080fd5b82018360208201111561079957600080fd5b803590602001918460208302840111600160201b831117156107ba57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550508235935050506020810135906001600160a01b036040820135811691606081013590911690608001356119de565b34801561082857600080fd5b506103d66004803603608081101561083f57600080fd5b810190602081018135600160201b81111561085957600080fd5b82018360208201111561086b57600080fd5b803590602001918460208302840111600160201b8311171561088c57600080fd5b91908080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525092955050823593505050602081013590604001356001600160a01b0316611a04565b3480156108ea57600080fd5b506101fe611a1e565b6103d6600480360360c081101561090957600080fd5b810190602081018135600160201b81111561092357600080fd5b82018360208201111561093557600080fd5b803590602001918460208302840111600160201b8311171561095657600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550508235935050506020810135906001600160a01b03604082013581169160608101359091169060800135611a4a565b6103d6600480360360c08110156109ce57600080fd5b810190602081018135600160201b8111156109e857600080fd5b8201836020820111156109fa57600080fd5b803590602001918460208302840111600160201b83111715610a1b57600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295505082359350505060208101359060408101359060608101359060800135611c25565b348015610a7c57600080fd5b506103d660048036036060811015610a9357600080fd5b810190602081018135600160201b811115610aad57600080fd5b820183602082011115610abf57600080fd5b803590602001918460208302840111600160201b83111715610ae057600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295505082359350505060200135611c38565b6103d66004803603608081101561083f57600080fd5b6103d66004803603610100811015610b5057600080fd5b810190602081018135600160201b811115610b6a57600080fd5b820183602082011115610b7c57600080fd5b803590602001918460208302840111600160201b83111715610b9d57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550508235935050506020810135906040810135906060810135906080810135906001600160a01b0360a0820135169060c00135611c52565b348015610c1357600080fd5b5061054e611dad565b348015610c2857600080fd5b50610c5760048036036040811015610c3f57600080fd5b506001600160a01b0381358116916020013516611dbc565b60408051602080825283518183015283519192839290830191858101910280838360005b83811015610c93578181015183820152602001610c7b565b505050509050019250505060405180910390f35b348015610cb357600080fd5b506103d6600480360360a081101561043c57600080fd5b348015610cd657600080fd5b506101fe60048036036020811015610ced57600080fd5b50356001600160a01b0316611f10565b6103d660048036036060811015610a9357600080fd5b348015610d1f57600080fd5b506101fe60048036036020811015610d3657600080fd5b5035611f8e565b610d45611fef565b60038054911515600160a01b0260ff60a01b19909216919091179055565b610d6b611fef565b81610d7581612044565b82610d7f81612098565b50506001600160a01b03919091166000908152600560205260409020805460ff1916911515919091179055565b600080610db98484611126565b946000945092505050565b6000610dd4878787878787611a4a565b979650505050505050565b600354600160a01b900460ff1681565b6000546001600160a01b0316331480610e125750600354600160a01b900460ff16155b610e57576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b6000610e756f436f6e7472616374526567697374727960801b6120ec565b6002549091506001600160a01b03808316911614801590610e9e57506001600160a01b03811615155b610ee6576040805162461bcd60e51b81526020600482015260146024820152734552525f494e56414c49445f524547495354525960601b604482015290519081900360640190fd5b60006001600160a01b0316816001600160a01b031663bb34534c6f436f6e7472616374526567697374727960801b6040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b158015610f4857600080fd5b505afa158015610f5c573d6000803e3d6000fd5b505050506040513d6020811015610f7257600080fd5b50516001600160a01b03161415610fc7576040805162461bcd60e51b81526020600482015260146024820152734552525f494e56414c49445f524547495354525960601b604482015290519081900360640190fd5b60028054600380546001600160a01b038084166001600160a01b0319928316179092559091169216919091179055565b600061100886868660008787611a4a565b9695505050505050565b60045481565b611020611fef565b8261102a81612044565b8261103481612044565b8361103e81612098565b61104986868661216c565b505050505050565b6003546001600160a01b031681565b6001546001600160a01b031633146110b3576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b600154600080546040516001600160a01b0393841693909116917f343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a91a360018054600080546001600160a01b03199081166001600160a01b03841617909155169055565b6002546001600160a01b031681565b60008060008060008060008061114b6c42616e636f72466f726d756c6160981b6120ec565b905088965060028a5111801561116c575060028a518161116757fe5b066001145b6111b0576040805162461bcd60e51b815260206004820152601060248201526f08aa4a4be929cac82989288bea082a8960831b604482015290519081900360640190fd5b60025b8a518110156118325760008b60028303815181106111cd57fe5b6020026020010151905060008c60018403815181106111e857fe5b6020026020010151905060008d848151811061120057fe5b60200260200101519050816001600160a01b0316638da5cb5b6040518163ffffffff1660e01b815260040160206040518083038186803b15801561124357600080fd5b505afa158015611257573d6000803e3d6000fd5b505050506040513d602081101561126d57600080fd5b5051955061127b86846122cc565b925061128786826122cc565b9050816001600160a01b0316816001600160a01b031614156115745760038410806112da57508d60038503815181106112bc57fe5b60200260200101516001600160a01b0316826001600160a01b031614155b1561134757816001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b15801561131857600080fd5b505afa15801561132c573d6000803e3d6000fd5b505050506040513d602081101561134257600080fd5b505198505b856001600160a01b031663d8959512846040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b15801561139457600080fd5b505afa1580156113a8573d6000803e3d6000fd5b505050506040513d60208110156113be57600080fd5b505160408051630e53aae960e01b81526001600160a01b0386811660048301529151929a5090881691630e53aae99160248082019260a092909190829003018186803b15801561140d57600080fd5b505afa158015611421573d6000803e3d6000fd5b505050506040513d60a081101561143757600080fd5b506020908101516040805163799287f160e11b8152600481018d9052602481018c905263ffffffff83166044820152606481018f905290519199506001600160a01b0388169263f3250fe292608480840193829003018186803b15801561149d57600080fd5b505afa1580156114b1573d6000803e3d6000fd5b505050506040513d60208110156114c757600080fd5b505160408051632bce69e560e11b81529051919c5061155c91620f424091611556916001600160a01b038b169163579cd3ca916004808301926020929190829003018186803b15801561151957600080fd5b505afa15801561152d573d6000803e3d6000fd5b505050506040513d602081101561154357600080fd5b50518e9063ffffffff9081169061232c16565b9061238a565b9a8b90039a995061156d898c6123e9565b9850611827565b816001600160a01b0316836001600160a01b031614156118155760038410806115c557508d60038503815181106115a757fe5b60200260200101516001600160a01b0316826001600160a01b031614155b1561163257816001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b15801561160357600080fd5b505afa158015611617573d6000803e3d6000fd5b505050506040513d602081101561162d57600080fd5b505198505b856001600160a01b031663d8959512826040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b15801561167f57600080fd5b505afa158015611693573d6000803e3d6000fd5b505050506040513d60208110156116a957600080fd5b505160408051630e53aae960e01b81526001600160a01b0384811660048301529151929a5090881691630e53aae99160248082019260a092909190829003018186803b1580156116f857600080fd5b505afa15801561170c573d6000803e3d6000fd5b505050506040513d60a081101561172257600080fd5b5060209081015160408051633b6785ab60e11b8152600481018d9052602481018c905263ffffffff83166044820152606481018f905290519199506001600160a01b038816926376cf0b5692608480840193829003018186803b15801561178857600080fd5b505afa15801561179c573d6000803e3d6000fd5b505050506040513d60208110156117b257600080fd5b505160408051632bce69e560e11b81529051919c5061180491620f424091611556916001600160a01b038b169163579cd3ca916004808301926020929190829003018186803b15801561151957600080fd5b9a8b90039a995061156d898c612432565b6118218684838e61247f565b909b5099505b5050506002016111b3565b509596505050505050505b92915050565b60056020526000908152604090205460ff1681565b6000846001600160a01b031663fc0c546a6040518163ffffffff1660e01b815260040160206040518083038186803b15801561189357600080fd5b505afa1580156118a7573d6000803e3d6000fd5b505050506040513d60208110156118bd57600080fd5b505186516001600160a01b039091169087906000906118d857fe5b60200260200101516001600160a01b03161461193b576040805162461bcd60e51b815260206004820152601860248201527f4552525f494e56414c49445f534f555243455f544f4b454e0000000000000000604482015290519081900360640190fd5b6000856001600160a01b031663aafd6b7686336040518363ffffffff1660e01b815260040180838152602001826001600160a01b031681526020019250505060206040518083038186803b15801561199257600080fd5b505afa1580156119a6573d6000803e3d6000fd5b505050506040513d60208110156119bc57600080fd5b50519050610dd487828686600080611a4a565b6000546001600160a01b031681565b6000846119ea816125f3565b6119f8888888888888611a4a565b98975050505050505050565b6000611a1585858585600080611a4a565b95945050505050565b611a26611fef565b600354600280546001600160a01b0319166001600160a01b03909216919091179055565b6000611a54612639565b6003805460ff60a81b1916600160a81b17905584611a71816125f3565b60028851118015611a8d57506002885181611a8857fe5b066001145b611ad1576040805162461bcd60e51b815260206004820152601060248201526f08aa4a4be929cac82989288bea082a8960831b604482015290519081900360640190fd5b611b0488600081518110611ae157fe5b602002602001015189600181518110611af657fe5b602002602001015189612689565b60006001600160a01b038516611b68578315611b63576040805162461bcd60e51b81526020600482015260196024820152784552525f494e56414c49445f414646494c494154455f46454560381b604482015290519081900360640190fd5b611bcb565b836000108015611b7a57506004548411155b611bc7576040805162461bcd60e51b81526020600482015260196024820152784552525f494e56414c49445f414646494c494154455f46454560381b604482015290519081900360640190fd5b5060015b336001600160a01b03871615611bde5750855b6060611beb8b8385612874565b90506000611bfc828c8c8b8b612c71565b9050611c09828285613145565b6003805460ff60a81b191690559b9a5050505050505050505050565b6000610dd4878787878787600080611c52565b6000611c4a8484846000806000611a4a565b949350505050565b600086611c5e816125f3565b60008a60018c510381518110611c7057fe5b602002602001015190506000611c8f66084c2dcc6dee4b60cb1b6120ec565b9050611ca56721272a2a37b5b2b760c11b6120ec565b6001600160a01b0316826001600160a01b031614611d0a576040805162461bcd60e51b815260206004820152601860248201527f4552525f494e56414c49445f5441524745545f544f4b454e0000000000000000604482015290519081900360640190fd5b6000611d1a8d8d8d308b8b611a4a565b9050611d27838383613223565b6040805163109f00dd60e21b8152600481018c9052602481018b905260448101839052606481018a905290516001600160a01b0384169163427c037491608480830192600092919082900301818387803b158015611d8457600080fd5b505af1158015611d98573d6000803e3d6000fd5b50929f9e505050505050505050505050505050565b6001546001600160a01b031681565b60606000611de07321b7b73b32b939b4b7b72830ba342334b73232b960611b6120ec565b9050806001600160a01b031663a1c421cd85856040518363ffffffff1660e01b815260040180836001600160a01b03168152602001826001600160a01b031681526020019250505060006040518083038186803b158015611e4057600080fd5b505afa158015611e54573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526020811015611e7d57600080fd5b8101908080516040519392919084600160201b821115611e9c57600080fd5b908301906020820185811115611eb157600080fd5b82518660208202830111600160201b82111715611ecd57600080fd5b82525081516020918201928201910280838360005b83811015611efa578181015183820152602001611ee2565b5050505090500160405250505091505092915050565b611f18611fef565b6000546001600160a01b0382811691161415611f6c576040805162461bcd60e51b815260206004820152600e60248201526d22a9292fa9a0a6a2afa7aba722a960911b604482015290519081900360640190fd5b600180546001600160a01b0319166001600160a01b0392909216919091179055565b611f96611fef565b620f4240811115611fea576040805162461bcd60e51b81526020600482015260196024820152784552525f494e56414c49445f414646494c494154455f46454560381b604482015290519081900360640190fd5b600455565b6000546001600160a01b03163314612042576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b565b6001600160a01b038116612095576040805162461bcd60e51b81526020600482015260136024820152724552525f494e56414c49445f4144445245535360681b604482015290519081900360640190fd5b50565b6001600160a01b038116301415612095576040805162461bcd60e51b815260206004820152601360248201527222a9292fa0a2222922a9a9afa4a9afa9a2a62360691b604482015290519081900360640190fd5b60025460408051632ecd14d360e21b81526004810184905290516000926001600160a01b03169163bb34534c916024808301926020929190829003018186803b15801561213857600080fd5b505afa15801561214c573d6000803e3d6000fd5b505050506040513d602081101561216257600080fd5b505190505b919050565b604080516001600160a01b038481166024830152604480830185905283518084039091018152606490920183526020820180516001600160e01b031663a9059cbb60e01b178152925182516000946060949389169392918291908083835b602083106121e95780518252601f1990920191602091820191016121ca565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d806000811461224b576040519150601f19603f3d011682016040523d82523d6000602084013e612250565b606091505b509150915081801561227e57508051158061227e575080806020019051602081101561227b57600080fd5b50515b6122c5576040805162461bcd60e51b815260206004820152601360248201527211549497d514905394d1915497d19052531151606a1b604482015290519081900360640190fd5b5050505050565b6001600160a01b03811660009081526005602052604081205460ff166122f357508061183d565b6122fc836132cd565b1561231c575073eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee61183d565b612325836133e4565b9392505050565b60008261233b5750600061183d565b8282028284828161234857fe5b0414612325576040805162461bcd60e51b815260206004820152600c60248201526b4552525f4f564552464c4f5760a01b604482015290519081900360640190fd5b60008082116123d5576040805162461bcd60e51b81526020600482015260126024820152714552525f4449564944455f42595f5a45524f60701b604482015290519081900360640190fd5b60008284816123e057fe5b04949350505050565b600082820183811015612325576040805162461bcd60e51b815260206004820152600c60248201526b4552525f4f564552464c4f5760a01b604482015290519081900360640190fd5b600081831015612479576040805162461bcd60e51b815260206004820152600d60248201526c4552525f554e444552464c4f5760981b604482015290519081900360640190fd5b50900390565b604080516001600160a01b0380861660248301528085166044830152606480830185905283518084039091018152608490920183526020820180516001600160e01b03166303c2803f60e31b178152925182516000948594938593606093918c169286928291908083835b602083106125095780518252601f1990920191602091820191016124ea565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855afa9150503d8060008114612569576040519150601f19603f3d011682016040523d82523d6000602084013e61256e565b606091505b509150915081156125df578051604014156125af5780806020019051604081101561259857600080fd5b50805160209091015190955093506125ea92505050565b8051602014156125df578080602001905160208110156125ce57600080fd5b50519450600093506125ea92505050565b600080945094505050505b94509492505050565b60008111612095576040805162461bcd60e51b815260206004820152600e60248201526d4552525f5a45524f5f56414c554560901b604482015290519081900360640190fd5b600354600160a81b900460ff1615612042576040805162461bcd60e51b815260206004820152600e60248201526d4552525f5245454e5452414e435960901b604482015290519081900360640190fd5b6000826001600160a01b0316638da5cb5b6040518163ffffffff1660e01b815260040160206040518083038186803b1580156126c457600080fd5b505afa1580156126d8573d6000803e3d6000fd5b505050506040513d60208110156126ee57600080fd5b5051905060006126fd826132cd565b905034156127c057823414612759576040805162461bcd60e51b815260206004820152601760248201527f4552525f4554485f414d4f554e545f4d49534d41544348000000000000000000604482015290519081900360640190fd5b806127bb57612767826133e4565b6001600160a01b031663d0e30db0346040518263ffffffff1660e01b81526004016000604051808303818588803b1580156127a157600080fd5b505af11580156127b5573d6000803e3d6000fd5b50505050505b6122c5565b6001600160a01b03851660009081526005602052604090205460ff1615612856576127ed85333086613523565b80156127bb57846001600160a01b0316632e1a7d4d846040518263ffffffff1660e01b815260040180828152602001915050600060405180830381600087803b15801561283957600080fd5b505af115801561284d573d6000803e3d6000fd5b505050506122c5565b8015612868576127bb85338486613523565b6122c585333086613523565b606080600285518161288257fe5b0467ffffffffffffffff8111801561289957600080fd5b506040519080825280602002602001820160405280156128d357816020015b6128c06137e6565b8152602001906001900390816128b85790505b5090506000806128ed6721272a2a37b5b2b760c11b6120ec565b905060005b6001885103811015612a8157600088826001018151811061290f57fe5b602002602001015190506000816001600160a01b0316638da5cb5b6040518163ffffffff1660e01b815260040160206040518083038186803b15801561295457600080fd5b505afa158015612968573d6000803e3d6000fd5b505050506040513d602081101561297e57600080fd5b50518a519091506000908b906002860190811061299757fe5b6020026020010151905060008980156129ae575086155b80156129cb5750856001600160a01b0316826001600160a01b0316145b905080156129d857600196505b6040518060e00160405280846001600160a01b03168152602001856001600160a01b031681526020018d8781518110612a0d57fe5b60200260200101516001600160a01b03168152602001836001600160a01b0316815260200160006001600160a01b03168152602001612a4b856132cd565b15158152821515602090910152886002870481518110612a6757fe5b6020026020010181905250505050506002810190506128f2565b612a896137e6565b84600081518110612a9657fe5b6020908102919091018101516040808201516001600160a01b0316600090815260059093529091205490915060ff1615612b0d578060a0015115612af35773eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee6040820152612b0d565b8051612afe906133e4565b6001600160a01b031660408201525b84600186510381518110612b1d57fe5b60209081029190910181015160608101516001600160a01b03166000908152600590925260409091205490915060ff1615612b95578060a0015115612b7b5773eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee6060820152612b95565b8051612b86906133e4565b6001600160a01b031660608201525b600091505b8451821015612c6457848281518110612baf57fe5b602002602001015190508060a0015115612c52578060c0015115612bd857306080820152612c4d565b6001855103821415612bf8576001600160a01b0388166080820152612c4d565b848260010181518110612c0757fe5b602002602001015160a0015115612c4657848260010181518110612c2757fe5b6020908102919091010151516001600160a01b03166080820152612c4d565b3060808201525b612c59565b3060808201525b600190910190612b9a565b5092979650505050505050565b60008085815b88518110156130ef57612c886137e6565b898281518110612c9457fe5b602002602001015190508060a0015115612d26578115801590612ce25750306001600160a01b03168a6001840381518110612ccb57fe5b6020026020010151608001516001600160a01b0316145b8015612d0957506040808201516001600160a01b031660009081526005602052205460ff16155b15612d2157612d21816040015182600001518561216c565b612d5a565b80602001516001600160a01b031681604001516001600160a01b031614612d5a57612d5a8160400151826000015185613223565b8060a00151612e0257805160408083015160608401518251635e5144eb60e01b81526001600160a01b039283166004820152908216602482015260448101879052600160648201529151921691635e5144eb916084808201926020929091908290030181600087803b158015612dcf57600080fd5b505af1158015612de3573d6000803e3d6000fd5b505050506040513d6020811015612df957600080fd5b50519350612f6d565b6040808201516001600160a01b031660009081526005602052205460ff1615612ec757805160408083015160608401516080850151835163e8dc12ff60e01b81526001600160a01b03938416600482015291831660248301526044820188905233606483015282166084820152915192169163e8dc12ff91349160a480830192602092919082900301818588803b158015612e9c57600080fd5b505af1158015612eb0573d6000803e3d6000fd5b50505050506040513d6020811015612df957600080fd5b805160408083015160608401516080850151835163e8dc12ff60e01b81526001600160a01b03938416600482015291831660248301526044820188905233606483015282166084820152915192169163e8dc12ff9160a4808201926020929091908290030181600087803b158015612f3e57600080fd5b505af1158015612f52573d6000803e3d6000fd5b505050506040513d6020811015612f6857600080fd5b505193505b8060c0015115613069576000612f8a620f4240611556878a61232c565b905081606001516001600160a01b031663a9059cbb89836040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050602060405180830381600087803b158015612fe757600080fd5b505af1158015612ffb573d6000803e3d6000fd5b505050506040513d602081101561301157600080fd5b5051613064576040805162461bcd60e51b815260206004820152601760248201527f4552525f4645455f5452414e534645525f4641494c4544000000000000000000604482015290519081900360640190fd5b909303925b80606001516001600160a01b031681604001516001600160a01b031682602001516001600160a01b03167f7154b38b5dd31bb3122436a96d4e09aba5b323ae1fd580025fab55074334c09586883360405180848152602001838152602001826001600160a01b03168152602001935050505060405180910390a450829150600101612c77565b508582101561313a576040805162461bcd60e51b81526020600482015260126024820152714552525f52455455524e5f544f4f5f4c4f5760701b604482015290519081900360640190fd5b509695505050505050565b61314d6137e6565b8360018551038151811061315d57fe5b60200260200101519050306001600160a01b031681608001516001600160a01b03161461318a575061321e565b60608101516001600160a01b03811660009081526005602052604090205460ff1615613213578160a00151156131bc57fe5b806001600160a01b031663205c287884866040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050600060405180830381600087803b15801561283957600080fd5b6122c581848661216c565b505050565b60408051636eb1769f60e11b81523060048201526001600160a01b038481166024830152915160009286169163dd62ed3e916044808301926020929190829003018186803b15801561327457600080fd5b505afa158015613288573d6000803e3d6000fd5b505050506040513d602081101561329e57600080fd5b50519050818110156132c75780156132bc576132bc8484600061368e565b6132c784848461368e565b50505050565b60408051600481526024810182526020810180516001600160e01b031663349814a760e21b1781529151815160009384926060926001600160a01b03881692610fa0928792909182918083835b602083106133395780518252601f19909201916020918201910161331a565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303818686fa925050503d806000811461339a576040519150601f19603f3d011682016040523d82523d6000602084013e61339f565b606091505b50915091508180156133b2575080516020145b156133d9578080602001905160208110156133cc57600080fd5b5051935061216792505050565b506000949350505050565b600080826001600160a01b03166371f52bf36040518163ffffffff1660e01b815260040160206040518083038186803b15801561342057600080fd5b505afa158015613434573d6000803e3d6000fd5b505050506040513d602081101561344a57600080fd5b505161ffff16905060005b81811015613506576000846001600160a01b03166319b64015836040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b1580156134a357600080fd5b505afa1580156134b7573d6000803e3d6000fd5b505050506040513d60208110156134cd57600080fd5b50516001600160a01b03811660009081526005602052604090205490915060ff16156134fd579250612167915050565b50600101613455565b5073eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee9392505050565b604080516001600160a01b0385811660248301528481166044830152606480830185905283518084039091018152608490920183526020820180516001600160e01b03166323b872dd60e01b17815292518251600094606094938a169392918291908083835b602083106135a85780518252601f199092019160209182019101613589565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d806000811461360a576040519150601f19603f3d011682016040523d82523d6000602084013e61360f565b606091505b509150915081801561363d57508051158061363d575080806020019051602081101561363a57600080fd5b50515b611049576040805162461bcd60e51b815260206004820152601860248201527f4552525f5452414e534645525f46524f4d5f4641494c45440000000000000000604482015290519081900360640190fd5b604080516001600160a01b038481166024830152604480830185905283518084039091018152606490920183526020820180516001600160e01b031663095ea7b360e01b178152925182516000946060949389169392918291908083835b6020831061370b5780518252601f1990920191602091820191016136ec565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d806000811461376d576040519150601f19603f3d011682016040523d82523d6000602084013e613772565b606091505b50915091508180156137a05750805115806137a0575080806020019051602081101561379d57600080fd5b50515b6122c5576040805162461bcd60e51b815260206004820152601260248201527111549497d054141493d59157d1905253115160721b604482015290519081900360640190fd5b6040805160e081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c08101919091529056fea264697066735822122077a4a6153a0865a6077a6c21f0e36ac3a1a2290bcb3ce1b21870501d7465c9e164736f6c634300060c0033",
+ "deployedBytecode": "0x6080604052600436106101cd5760003560e01c80638da5cb5b116100f7578063c98fefed11610095578063e57738e511610064578063e57738e514610ca7578063f2fde38b14610cca578063f3898a9714610cfd578063f3bc7d2a14610d13576101cd565b8063c98fefed14610b23578063cb32564e14610b39578063d4ee1d9014610c07578063d734fa1914610c1c576101cd565b8063b4a176d3116100d1578063b4a176d3146108de578063b77d239b146108f3578063c52173de146109b8578063c7ba24bc14610a70576101cd565b80638da5cb5b14610742578063ab6214ce14610757578063b1e9932b1461081c576101cd565b80635d732ff21161016f5780637b1039991161013e5780637b1039991461057f5780637f9c0ecd146105945780638077ccf71461064457806389f9cc6114610677576101cd565b80635d732ff2146104e15780635e35359e146104f657806361cd756e1461053957806379ba50971461056a576101cd565b80632978c10e116101ab5780632978c10e146103045780632fe8a6ad146103e857806349d10b6414610411578063569706eb14610426576101cd565b8063024c7ec7146101d257806302ef521e146102005780630c8496cc1461023b575b600080fd5b3480156101de57600080fd5b506101fe600480360360208110156101f557600080fd5b50351515610d3d565b005b34801561020c57600080fd5b506101fe6004803603604081101561022357600080fd5b506001600160a01b0381351690602001351515610d63565b34801561024757600080fd5b506102eb6004803603604081101561025e57600080fd5b810190602081018135600160201b81111561027857600080fd5b82018360208201111561028a57600080fd5b803590602001918460208302840111600160201b831117156102ab57600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295505091359250610dac915050565b6040805192835260208301919091528051918290030190f35b34801561031057600080fd5b506103d6600480360360c081101561032757600080fd5b810190602081018135600160201b81111561034157600080fd5b82018360208201111561035357600080fd5b803590602001918460208302840111600160201b8311171561037457600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550508235935050506020810135906001600160a01b03604082013581169160608101359091169060800135610dc4565b60408051918252519081900360200190f35b3480156103f457600080fd5b506103fd610ddf565b604080519115158252519081900360200190f35b34801561041d57600080fd5b506101fe610def565b6103d6600480360360a081101561043c57600080fd5b810190602081018135600160201b81111561045657600080fd5b82018360208201111561046857600080fd5b803590602001918460208302840111600160201b8311171561048957600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550508235935050506020810135906001600160a01b036040820135169060600135610ff7565b3480156104ed57600080fd5b506103d6611012565b34801561050257600080fd5b506101fe6004803603606081101561051957600080fd5b506001600160a01b03813581169160208101359091169060400135611018565b34801561054557600080fd5b5061054e611051565b604080516001600160a01b039092168252519081900360200190f35b34801561057657600080fd5b506101fe611060565b34801561058b57600080fd5b5061054e611117565b3480156105a057600080fd5b506103d6600480360360408110156105b757600080fd5b810190602081018135600160201b8111156105d157600080fd5b8201836020820111156105e357600080fd5b803590602001918460208302840111600160201b8311171561060457600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295505091359250611126915050565b34801561065057600080fd5b506103fd6004803603602081101561066757600080fd5b50356001600160a01b0316611843565b34801561068357600080fd5b506103d6600480360360a081101561069a57600080fd5b810190602081018135600160201b8111156106b457600080fd5b8201836020820111156106c657600080fd5b803590602001918460208302840111600160201b831117156106e757600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550506001600160a01b038335811694506020840135936040810135935060600135169050611858565b34801561074e57600080fd5b5061054e6119cf565b6103d6600480360360c081101561076d57600080fd5b810190602081018135600160201b81111561078757600080fd5b82018360208201111561079957600080fd5b803590602001918460208302840111600160201b831117156107ba57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550508235935050506020810135906001600160a01b036040820135811691606081013590911690608001356119de565b34801561082857600080fd5b506103d66004803603608081101561083f57600080fd5b810190602081018135600160201b81111561085957600080fd5b82018360208201111561086b57600080fd5b803590602001918460208302840111600160201b8311171561088c57600080fd5b91908080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525092955050823593505050602081013590604001356001600160a01b0316611a04565b3480156108ea57600080fd5b506101fe611a1e565b6103d6600480360360c081101561090957600080fd5b810190602081018135600160201b81111561092357600080fd5b82018360208201111561093557600080fd5b803590602001918460208302840111600160201b8311171561095657600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550508235935050506020810135906001600160a01b03604082013581169160608101359091169060800135611a4a565b6103d6600480360360c08110156109ce57600080fd5b810190602081018135600160201b8111156109e857600080fd5b8201836020820111156109fa57600080fd5b803590602001918460208302840111600160201b83111715610a1b57600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295505082359350505060208101359060408101359060608101359060800135611c25565b348015610a7c57600080fd5b506103d660048036036060811015610a9357600080fd5b810190602081018135600160201b811115610aad57600080fd5b820183602082011115610abf57600080fd5b803590602001918460208302840111600160201b83111715610ae057600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295505082359350505060200135611c38565b6103d66004803603608081101561083f57600080fd5b6103d66004803603610100811015610b5057600080fd5b810190602081018135600160201b811115610b6a57600080fd5b820183602082011115610b7c57600080fd5b803590602001918460208302840111600160201b83111715610b9d57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550508235935050506020810135906040810135906060810135906080810135906001600160a01b0360a0820135169060c00135611c52565b348015610c1357600080fd5b5061054e611dad565b348015610c2857600080fd5b50610c5760048036036040811015610c3f57600080fd5b506001600160a01b0381358116916020013516611dbc565b60408051602080825283518183015283519192839290830191858101910280838360005b83811015610c93578181015183820152602001610c7b565b505050509050019250505060405180910390f35b348015610cb357600080fd5b506103d6600480360360a081101561043c57600080fd5b348015610cd657600080fd5b506101fe60048036036020811015610ced57600080fd5b50356001600160a01b0316611f10565b6103d660048036036060811015610a9357600080fd5b348015610d1f57600080fd5b506101fe60048036036020811015610d3657600080fd5b5035611f8e565b610d45611fef565b60038054911515600160a01b0260ff60a01b19909216919091179055565b610d6b611fef565b81610d7581612044565b82610d7f81612098565b50506001600160a01b03919091166000908152600560205260409020805460ff1916911515919091179055565b600080610db98484611126565b946000945092505050565b6000610dd4878787878787611a4a565b979650505050505050565b600354600160a01b900460ff1681565b6000546001600160a01b0316331480610e125750600354600160a01b900460ff16155b610e57576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b6000610e756f436f6e7472616374526567697374727960801b6120ec565b6002549091506001600160a01b03808316911614801590610e9e57506001600160a01b03811615155b610ee6576040805162461bcd60e51b81526020600482015260146024820152734552525f494e56414c49445f524547495354525960601b604482015290519081900360640190fd5b60006001600160a01b0316816001600160a01b031663bb34534c6f436f6e7472616374526567697374727960801b6040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b158015610f4857600080fd5b505afa158015610f5c573d6000803e3d6000fd5b505050506040513d6020811015610f7257600080fd5b50516001600160a01b03161415610fc7576040805162461bcd60e51b81526020600482015260146024820152734552525f494e56414c49445f524547495354525960601b604482015290519081900360640190fd5b60028054600380546001600160a01b038084166001600160a01b0319928316179092559091169216919091179055565b600061100886868660008787611a4a565b9695505050505050565b60045481565b611020611fef565b8261102a81612044565b8261103481612044565b8361103e81612098565b61104986868661216c565b505050505050565b6003546001600160a01b031681565b6001546001600160a01b031633146110b3576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b600154600080546040516001600160a01b0393841693909116917f343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a91a360018054600080546001600160a01b03199081166001600160a01b03841617909155169055565b6002546001600160a01b031681565b60008060008060008060008061114b6c42616e636f72466f726d756c6160981b6120ec565b905088965060028a5111801561116c575060028a518161116757fe5b066001145b6111b0576040805162461bcd60e51b815260206004820152601060248201526f08aa4a4be929cac82989288bea082a8960831b604482015290519081900360640190fd5b60025b8a518110156118325760008b60028303815181106111cd57fe5b6020026020010151905060008c60018403815181106111e857fe5b6020026020010151905060008d848151811061120057fe5b60200260200101519050816001600160a01b0316638da5cb5b6040518163ffffffff1660e01b815260040160206040518083038186803b15801561124357600080fd5b505afa158015611257573d6000803e3d6000fd5b505050506040513d602081101561126d57600080fd5b5051955061127b86846122cc565b925061128786826122cc565b9050816001600160a01b0316816001600160a01b031614156115745760038410806112da57508d60038503815181106112bc57fe5b60200260200101516001600160a01b0316826001600160a01b031614155b1561134757816001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b15801561131857600080fd5b505afa15801561132c573d6000803e3d6000fd5b505050506040513d602081101561134257600080fd5b505198505b856001600160a01b031663d8959512846040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b15801561139457600080fd5b505afa1580156113a8573d6000803e3d6000fd5b505050506040513d60208110156113be57600080fd5b505160408051630e53aae960e01b81526001600160a01b0386811660048301529151929a5090881691630e53aae99160248082019260a092909190829003018186803b15801561140d57600080fd5b505afa158015611421573d6000803e3d6000fd5b505050506040513d60a081101561143757600080fd5b506020908101516040805163799287f160e11b8152600481018d9052602481018c905263ffffffff83166044820152606481018f905290519199506001600160a01b0388169263f3250fe292608480840193829003018186803b15801561149d57600080fd5b505afa1580156114b1573d6000803e3d6000fd5b505050506040513d60208110156114c757600080fd5b505160408051632bce69e560e11b81529051919c5061155c91620f424091611556916001600160a01b038b169163579cd3ca916004808301926020929190829003018186803b15801561151957600080fd5b505afa15801561152d573d6000803e3d6000fd5b505050506040513d602081101561154357600080fd5b50518e9063ffffffff9081169061232c16565b9061238a565b9a8b90039a995061156d898c6123e9565b9850611827565b816001600160a01b0316836001600160a01b031614156118155760038410806115c557508d60038503815181106115a757fe5b60200260200101516001600160a01b0316826001600160a01b031614155b1561163257816001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b15801561160357600080fd5b505afa158015611617573d6000803e3d6000fd5b505050506040513d602081101561162d57600080fd5b505198505b856001600160a01b031663d8959512826040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b15801561167f57600080fd5b505afa158015611693573d6000803e3d6000fd5b505050506040513d60208110156116a957600080fd5b505160408051630e53aae960e01b81526001600160a01b0384811660048301529151929a5090881691630e53aae99160248082019260a092909190829003018186803b1580156116f857600080fd5b505afa15801561170c573d6000803e3d6000fd5b505050506040513d60a081101561172257600080fd5b5060209081015160408051633b6785ab60e11b8152600481018d9052602481018c905263ffffffff83166044820152606481018f905290519199506001600160a01b038816926376cf0b5692608480840193829003018186803b15801561178857600080fd5b505afa15801561179c573d6000803e3d6000fd5b505050506040513d60208110156117b257600080fd5b505160408051632bce69e560e11b81529051919c5061180491620f424091611556916001600160a01b038b169163579cd3ca916004808301926020929190829003018186803b15801561151957600080fd5b9a8b90039a995061156d898c612432565b6118218684838e61247f565b909b5099505b5050506002016111b3565b509596505050505050505b92915050565b60056020526000908152604090205460ff1681565b6000846001600160a01b031663fc0c546a6040518163ffffffff1660e01b815260040160206040518083038186803b15801561189357600080fd5b505afa1580156118a7573d6000803e3d6000fd5b505050506040513d60208110156118bd57600080fd5b505186516001600160a01b039091169087906000906118d857fe5b60200260200101516001600160a01b03161461193b576040805162461bcd60e51b815260206004820152601860248201527f4552525f494e56414c49445f534f555243455f544f4b454e0000000000000000604482015290519081900360640190fd5b6000856001600160a01b031663aafd6b7686336040518363ffffffff1660e01b815260040180838152602001826001600160a01b031681526020019250505060206040518083038186803b15801561199257600080fd5b505afa1580156119a6573d6000803e3d6000fd5b505050506040513d60208110156119bc57600080fd5b50519050610dd487828686600080611a4a565b6000546001600160a01b031681565b6000846119ea816125f3565b6119f8888888888888611a4a565b98975050505050505050565b6000611a1585858585600080611a4a565b95945050505050565b611a26611fef565b600354600280546001600160a01b0319166001600160a01b03909216919091179055565b6000611a54612639565b6003805460ff60a81b1916600160a81b17905584611a71816125f3565b60028851118015611a8d57506002885181611a8857fe5b066001145b611ad1576040805162461bcd60e51b815260206004820152601060248201526f08aa4a4be929cac82989288bea082a8960831b604482015290519081900360640190fd5b611b0488600081518110611ae157fe5b602002602001015189600181518110611af657fe5b602002602001015189612689565b60006001600160a01b038516611b68578315611b63576040805162461bcd60e51b81526020600482015260196024820152784552525f494e56414c49445f414646494c494154455f46454560381b604482015290519081900360640190fd5b611bcb565b836000108015611b7a57506004548411155b611bc7576040805162461bcd60e51b81526020600482015260196024820152784552525f494e56414c49445f414646494c494154455f46454560381b604482015290519081900360640190fd5b5060015b336001600160a01b03871615611bde5750855b6060611beb8b8385612874565b90506000611bfc828c8c8b8b612c71565b9050611c09828285613145565b6003805460ff60a81b191690559b9a5050505050505050505050565b6000610dd4878787878787600080611c52565b6000611c4a8484846000806000611a4a565b949350505050565b600086611c5e816125f3565b60008a60018c510381518110611c7057fe5b602002602001015190506000611c8f66084c2dcc6dee4b60cb1b6120ec565b9050611ca56721272a2a37b5b2b760c11b6120ec565b6001600160a01b0316826001600160a01b031614611d0a576040805162461bcd60e51b815260206004820152601860248201527f4552525f494e56414c49445f5441524745545f544f4b454e0000000000000000604482015290519081900360640190fd5b6000611d1a8d8d8d308b8b611a4a565b9050611d27838383613223565b6040805163109f00dd60e21b8152600481018c9052602481018b905260448101839052606481018a905290516001600160a01b0384169163427c037491608480830192600092919082900301818387803b158015611d8457600080fd5b505af1158015611d98573d6000803e3d6000fd5b50929f9e505050505050505050505050505050565b6001546001600160a01b031681565b60606000611de07321b7b73b32b939b4b7b72830ba342334b73232b960611b6120ec565b9050806001600160a01b031663a1c421cd85856040518363ffffffff1660e01b815260040180836001600160a01b03168152602001826001600160a01b031681526020019250505060006040518083038186803b158015611e4057600080fd5b505afa158015611e54573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526020811015611e7d57600080fd5b8101908080516040519392919084600160201b821115611e9c57600080fd5b908301906020820185811115611eb157600080fd5b82518660208202830111600160201b82111715611ecd57600080fd5b82525081516020918201928201910280838360005b83811015611efa578181015183820152602001611ee2565b5050505090500160405250505091505092915050565b611f18611fef565b6000546001600160a01b0382811691161415611f6c576040805162461bcd60e51b815260206004820152600e60248201526d22a9292fa9a0a6a2afa7aba722a960911b604482015290519081900360640190fd5b600180546001600160a01b0319166001600160a01b0392909216919091179055565b611f96611fef565b620f4240811115611fea576040805162461bcd60e51b81526020600482015260196024820152784552525f494e56414c49445f414646494c494154455f46454560381b604482015290519081900360640190fd5b600455565b6000546001600160a01b03163314612042576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b565b6001600160a01b038116612095576040805162461bcd60e51b81526020600482015260136024820152724552525f494e56414c49445f4144445245535360681b604482015290519081900360640190fd5b50565b6001600160a01b038116301415612095576040805162461bcd60e51b815260206004820152601360248201527222a9292fa0a2222922a9a9afa4a9afa9a2a62360691b604482015290519081900360640190fd5b60025460408051632ecd14d360e21b81526004810184905290516000926001600160a01b03169163bb34534c916024808301926020929190829003018186803b15801561213857600080fd5b505afa15801561214c573d6000803e3d6000fd5b505050506040513d602081101561216257600080fd5b505190505b919050565b604080516001600160a01b038481166024830152604480830185905283518084039091018152606490920183526020820180516001600160e01b031663a9059cbb60e01b178152925182516000946060949389169392918291908083835b602083106121e95780518252601f1990920191602091820191016121ca565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d806000811461224b576040519150601f19603f3d011682016040523d82523d6000602084013e612250565b606091505b509150915081801561227e57508051158061227e575080806020019051602081101561227b57600080fd5b50515b6122c5576040805162461bcd60e51b815260206004820152601360248201527211549497d514905394d1915497d19052531151606a1b604482015290519081900360640190fd5b5050505050565b6001600160a01b03811660009081526005602052604081205460ff166122f357508061183d565b6122fc836132cd565b1561231c575073eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee61183d565b612325836133e4565b9392505050565b60008261233b5750600061183d565b8282028284828161234857fe5b0414612325576040805162461bcd60e51b815260206004820152600c60248201526b4552525f4f564552464c4f5760a01b604482015290519081900360640190fd5b60008082116123d5576040805162461bcd60e51b81526020600482015260126024820152714552525f4449564944455f42595f5a45524f60701b604482015290519081900360640190fd5b60008284816123e057fe5b04949350505050565b600082820183811015612325576040805162461bcd60e51b815260206004820152600c60248201526b4552525f4f564552464c4f5760a01b604482015290519081900360640190fd5b600081831015612479576040805162461bcd60e51b815260206004820152600d60248201526c4552525f554e444552464c4f5760981b604482015290519081900360640190fd5b50900390565b604080516001600160a01b0380861660248301528085166044830152606480830185905283518084039091018152608490920183526020820180516001600160e01b03166303c2803f60e31b178152925182516000948594938593606093918c169286928291908083835b602083106125095780518252601f1990920191602091820191016124ea565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855afa9150503d8060008114612569576040519150601f19603f3d011682016040523d82523d6000602084013e61256e565b606091505b509150915081156125df578051604014156125af5780806020019051604081101561259857600080fd5b50805160209091015190955093506125ea92505050565b8051602014156125df578080602001905160208110156125ce57600080fd5b50519450600093506125ea92505050565b600080945094505050505b94509492505050565b60008111612095576040805162461bcd60e51b815260206004820152600e60248201526d4552525f5a45524f5f56414c554560901b604482015290519081900360640190fd5b600354600160a81b900460ff1615612042576040805162461bcd60e51b815260206004820152600e60248201526d4552525f5245454e5452414e435960901b604482015290519081900360640190fd5b6000826001600160a01b0316638da5cb5b6040518163ffffffff1660e01b815260040160206040518083038186803b1580156126c457600080fd5b505afa1580156126d8573d6000803e3d6000fd5b505050506040513d60208110156126ee57600080fd5b5051905060006126fd826132cd565b905034156127c057823414612759576040805162461bcd60e51b815260206004820152601760248201527f4552525f4554485f414d4f554e545f4d49534d41544348000000000000000000604482015290519081900360640190fd5b806127bb57612767826133e4565b6001600160a01b031663d0e30db0346040518263ffffffff1660e01b81526004016000604051808303818588803b1580156127a157600080fd5b505af11580156127b5573d6000803e3d6000fd5b50505050505b6122c5565b6001600160a01b03851660009081526005602052604090205460ff1615612856576127ed85333086613523565b80156127bb57846001600160a01b0316632e1a7d4d846040518263ffffffff1660e01b815260040180828152602001915050600060405180830381600087803b15801561283957600080fd5b505af115801561284d573d6000803e3d6000fd5b505050506122c5565b8015612868576127bb85338486613523565b6122c585333086613523565b606080600285518161288257fe5b0467ffffffffffffffff8111801561289957600080fd5b506040519080825280602002602001820160405280156128d357816020015b6128c06137e6565b8152602001906001900390816128b85790505b5090506000806128ed6721272a2a37b5b2b760c11b6120ec565b905060005b6001885103811015612a8157600088826001018151811061290f57fe5b602002602001015190506000816001600160a01b0316638da5cb5b6040518163ffffffff1660e01b815260040160206040518083038186803b15801561295457600080fd5b505afa158015612968573d6000803e3d6000fd5b505050506040513d602081101561297e57600080fd5b50518a519091506000908b906002860190811061299757fe5b6020026020010151905060008980156129ae575086155b80156129cb5750856001600160a01b0316826001600160a01b0316145b905080156129d857600196505b6040518060e00160405280846001600160a01b03168152602001856001600160a01b031681526020018d8781518110612a0d57fe5b60200260200101516001600160a01b03168152602001836001600160a01b0316815260200160006001600160a01b03168152602001612a4b856132cd565b15158152821515602090910152886002870481518110612a6757fe5b6020026020010181905250505050506002810190506128f2565b612a896137e6565b84600081518110612a9657fe5b6020908102919091018101516040808201516001600160a01b0316600090815260059093529091205490915060ff1615612b0d578060a0015115612af35773eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee6040820152612b0d565b8051612afe906133e4565b6001600160a01b031660408201525b84600186510381518110612b1d57fe5b60209081029190910181015160608101516001600160a01b03166000908152600590925260409091205490915060ff1615612b95578060a0015115612b7b5773eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee6060820152612b95565b8051612b86906133e4565b6001600160a01b031660608201525b600091505b8451821015612c6457848281518110612baf57fe5b602002602001015190508060a0015115612c52578060c0015115612bd857306080820152612c4d565b6001855103821415612bf8576001600160a01b0388166080820152612c4d565b848260010181518110612c0757fe5b602002602001015160a0015115612c4657848260010181518110612c2757fe5b6020908102919091010151516001600160a01b03166080820152612c4d565b3060808201525b612c59565b3060808201525b600190910190612b9a565b5092979650505050505050565b60008085815b88518110156130ef57612c886137e6565b898281518110612c9457fe5b602002602001015190508060a0015115612d26578115801590612ce25750306001600160a01b03168a6001840381518110612ccb57fe5b6020026020010151608001516001600160a01b0316145b8015612d0957506040808201516001600160a01b031660009081526005602052205460ff16155b15612d2157612d21816040015182600001518561216c565b612d5a565b80602001516001600160a01b031681604001516001600160a01b031614612d5a57612d5a8160400151826000015185613223565b8060a00151612e0257805160408083015160608401518251635e5144eb60e01b81526001600160a01b039283166004820152908216602482015260448101879052600160648201529151921691635e5144eb916084808201926020929091908290030181600087803b158015612dcf57600080fd5b505af1158015612de3573d6000803e3d6000fd5b505050506040513d6020811015612df957600080fd5b50519350612f6d565b6040808201516001600160a01b031660009081526005602052205460ff1615612ec757805160408083015160608401516080850151835163e8dc12ff60e01b81526001600160a01b03938416600482015291831660248301526044820188905233606483015282166084820152915192169163e8dc12ff91349160a480830192602092919082900301818588803b158015612e9c57600080fd5b505af1158015612eb0573d6000803e3d6000fd5b50505050506040513d6020811015612df957600080fd5b805160408083015160608401516080850151835163e8dc12ff60e01b81526001600160a01b03938416600482015291831660248301526044820188905233606483015282166084820152915192169163e8dc12ff9160a4808201926020929091908290030181600087803b158015612f3e57600080fd5b505af1158015612f52573d6000803e3d6000fd5b505050506040513d6020811015612f6857600080fd5b505193505b8060c0015115613069576000612f8a620f4240611556878a61232c565b905081606001516001600160a01b031663a9059cbb89836040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050602060405180830381600087803b158015612fe757600080fd5b505af1158015612ffb573d6000803e3d6000fd5b505050506040513d602081101561301157600080fd5b5051613064576040805162461bcd60e51b815260206004820152601760248201527f4552525f4645455f5452414e534645525f4641494c4544000000000000000000604482015290519081900360640190fd5b909303925b80606001516001600160a01b031681604001516001600160a01b031682602001516001600160a01b03167f7154b38b5dd31bb3122436a96d4e09aba5b323ae1fd580025fab55074334c09586883360405180848152602001838152602001826001600160a01b03168152602001935050505060405180910390a450829150600101612c77565b508582101561313a576040805162461bcd60e51b81526020600482015260126024820152714552525f52455455524e5f544f4f5f4c4f5760701b604482015290519081900360640190fd5b509695505050505050565b61314d6137e6565b8360018551038151811061315d57fe5b60200260200101519050306001600160a01b031681608001516001600160a01b03161461318a575061321e565b60608101516001600160a01b03811660009081526005602052604090205460ff1615613213578160a00151156131bc57fe5b806001600160a01b031663205c287884866040518363ffffffff1660e01b815260040180836001600160a01b0316815260200182815260200192505050600060405180830381600087803b15801561283957600080fd5b6122c581848661216c565b505050565b60408051636eb1769f60e11b81523060048201526001600160a01b038481166024830152915160009286169163dd62ed3e916044808301926020929190829003018186803b15801561327457600080fd5b505afa158015613288573d6000803e3d6000fd5b505050506040513d602081101561329e57600080fd5b50519050818110156132c75780156132bc576132bc8484600061368e565b6132c784848461368e565b50505050565b60408051600481526024810182526020810180516001600160e01b031663349814a760e21b1781529151815160009384926060926001600160a01b03881692610fa0928792909182918083835b602083106133395780518252601f19909201916020918201910161331a565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303818686fa925050503d806000811461339a576040519150601f19603f3d011682016040523d82523d6000602084013e61339f565b606091505b50915091508180156133b2575080516020145b156133d9578080602001905160208110156133cc57600080fd5b5051935061216792505050565b506000949350505050565b600080826001600160a01b03166371f52bf36040518163ffffffff1660e01b815260040160206040518083038186803b15801561342057600080fd5b505afa158015613434573d6000803e3d6000fd5b505050506040513d602081101561344a57600080fd5b505161ffff16905060005b81811015613506576000846001600160a01b03166319b64015836040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b1580156134a357600080fd5b505afa1580156134b7573d6000803e3d6000fd5b505050506040513d60208110156134cd57600080fd5b50516001600160a01b03811660009081526005602052604090205490915060ff16156134fd579250612167915050565b50600101613455565b5073eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee9392505050565b604080516001600160a01b0385811660248301528481166044830152606480830185905283518084039091018152608490920183526020820180516001600160e01b03166323b872dd60e01b17815292518251600094606094938a169392918291908083835b602083106135a85780518252601f199092019160209182019101613589565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d806000811461360a576040519150601f19603f3d011682016040523d82523d6000602084013e61360f565b606091505b509150915081801561363d57508051158061363d575080806020019051602081101561363a57600080fd5b50515b611049576040805162461bcd60e51b815260206004820152601860248201527f4552525f5452414e534645525f46524f4d5f4641494c45440000000000000000604482015290519081900360640190fd5b604080516001600160a01b038481166024830152604480830185905283518084039091018152606490920183526020820180516001600160e01b031663095ea7b360e01b178152925182516000946060949389169392918291908083835b6020831061370b5780518252601f1990920191602091820191016136ec565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d806000811461376d576040519150601f19603f3d011682016040523d82523d6000602084013e613772565b606091505b50915091508180156137a05750805115806137a0575080806020019051602081101561379d57600080fd5b50515b6122c5576040805162461bcd60e51b815260206004820152601260248201527111549497d054141493d59157d1905253115160721b604482015290519081900360640190fd5b6040805160e081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c08101919091529056fea264697066735822122077a4a6153a0865a6077a6c21f0e36ac3a1a2290bcb3ce1b21870501d7465c9e164736f6c634300060c0033",
+ "immutableReferences": {},
+ "sourceMap": "1956:32561:0:-:0;;;349:27:59;;;-1:-1:-1;;;;349:27:59;;;2563:5:0;2530:38;;3543:140;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;3543:140:0;619:5:57;:18;;-1:-1:-1;;;;;;619:18:57;627:10;619:18;;;3543:140:0;;594:23:64;3543:140:0;594:13:64;:23::i;:::-;-1:-1:-1;2122:8:56::1;:39:::0;;-1:-1:-1;;;;;2122:39:56;;::::1;-1:-1:-1::0;;;;;;2122:39:56;;::::1;::::0;::::1;::::0;;;2172:12:::1;:43:::0;;;;::::1;;::::0;;-1:-1:-1;2196:42:0::1;2122:8:56;3636:32:0::0;:11:::1;:32;::::0;;:39;;-1:-1:-1;;3636:39:0::1;2122::56::0;3636::0::1;::::0;;1956:32561;;692:128:64;-1:-1:-1;;;;;766:22:64;;758:54;;;;;-1:-1:-1;;;758:54:64;;;;;;;;;;;;;;;;;;;;;;;;;;;;692:128;:::o;1956:32561:0:-;;;;;;;",
+ "deployedSourceMap": "1956:32561:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3655:224:56;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;3655:224:56;;;;:::i;:::-;;4297:227:0;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;4297:227:0;;;;;;;;;;:::i;31327:162::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;31327:162:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;31327:162:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;31327:162:0;;-1:-1:-1;;31327:162:0;;;-1:-1:-1;31327:162:0;;-1:-1:-1;;31327:162:0:i;:::-;;;;;;;;;;;;;;;;;;;;;;;34120:394;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;34120:394:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;34120:394:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;34120:394:0;;-1:-1:-1;;34120:394:0;;;-1:-1:-1;;;34120:394:0;;;;;-1:-1:-1;;;;;34120:394:0;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;1333:38:56;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;2300:925;;;;;;;;;;;;;:::i;31842:359:0:-;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;31842:359:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;31842:359:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;31842:359:0;;-1:-1:-1;;31842:359:0;;;-1:-1:-1;;;31842:359:0;;;;;-1:-1:-1;;;;;31842:359:0;;;;;;;;;;:::i;2530:38::-;;;;;;;;;;;;;:::i;1196:290:62:-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;1196:290:62;;;;;;;;;;;;;;;;;:::i;1243:37:56:-;;;;;;;;;;;;;:::i;:::-;;;;-1:-1:-1;;;;;1243:37:56;;;;;;;;;;;;;;1422:217:57;;;;;;;;;;;;;:::i;1154:33:56:-;;;;;;;;;;;;;:::i;5591:2853:0:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;5591:2853:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;5591:2853:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;5591:2853:0;;-1:-1:-1;;5591:2853:0;;;-1:-1:-1;5591:2853:0;;-1:-1:-1;;5591:2853:0:i;2606:48::-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;2606:48:0;-1:-1:-1;;;;;2606:48:0;;:::i;15856:607::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;15856:607:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;15856:607:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;15856:607:0;;-1:-1:-1;;;;;;;15856:607:0;;;;;-1:-1:-1;15856:607:0;;;;;;;;;;-1:-1:-1;15856:607:0;;;;;-1:-1:-1;15856:607:0;:::i;219:29:57:-;;;;;;;;;;;;;:::i;32589:440:0:-;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;32589:440:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;32589:440:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;32589:440:0;;-1:-1:-1;;32589:440:0;;;-1:-1:-1;;;32589:440:0;;;;;-1:-1:-1;;;;;32589:440:0;;;;;;;;;;;;;;;;;;;:::i;33806:240::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;33806:240:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;33806:240:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;33806:240:0;;-1:-1:-1;;33806:240:0;;;-1:-1:-1;;;33806:240:0;;;;;;;;-1:-1:-1;;;;;33806:240:0;;:::i;3304:137:56:-;;;;;;;;;;;;;:::i;9608:1669:0:-;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;9608:1669:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;9608:1669:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;9608:1669:0;;-1:-1:-1;;9608:1669:0;;;-1:-1:-1;;;9608:1669:0;;;;;-1:-1:-1;;;;;9608:1669:0;;;;;;;;;;;;;;;;;;;:::i;12269:407::-;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;12269:407:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;12269:407:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;12269:407:0;;-1:-1:-1;;12269:407:0;;;-1:-1:-1;;;12269:407:0;;;;;;;;;;;;;;;;;;;:::i;33103:205::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;33103:205:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;33103:205:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;33103:205:0;;-1:-1:-1;;33103:205:0;;;-1:-1:-1;;;33103:205:0;;;;:::i;32275:240::-;;;;;;;;;;;;;;;13781:1124;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;13781:1124:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;13781:1124:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;13781:1124:0;;-1:-1:-1;;13781:1124:0;;;-1:-1:-1;;;13781:1124:0;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;13781:1124:0;;;;;;;;;;:::i;255:23:57:-;;;;;;;;;;;;;:::i;4906:290:0:-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;4906:290:0;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;33382:350;;;;;;;;;;;;;;;;;;;;;;;;;1164:167:57;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;1164:167:57;-1:-1:-1;;;;;1164:167:57;;:::i;31563:205:0:-;;;;;;;;;;;;;;;3841:230;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;3841:230:0;;:::i;3655:224:56:-;726:12:57;:10;:12::i;:::-;3815:26:56::1;:56:::0;;;::::1;;-1:-1:-1::0;;;3815:56:56::1;-1:-1:-1::0;;;;3815:56:56;;::::1;::::0;;;::::1;::::0;;3655:224::o;4297:227:0:-;726:12:57;:10;:12::i;:::-;4426:6:0::1;594:23:64;608:8;594:13;:23::i;:::-;4460:6:0::2;948:18:64;957:8;948;:18::i;:::-;-1:-1:-1::0;;;;;;;4485:19:0;;;::::3;;::::0;;;:11:::3;:19;::::0;;;;:31;;-1:-1:-1;;4485:31:0::3;::::0;::::3;;::::0;;;::::3;::::0;;4297:227::o;31327:162::-;31414:7;31423;31451:26;31462:5;31469:7;31451:10;:26::i;:::-;31443:38;31479:1;;-1:-1:-1;31327:162:0;-1:-1:-1;;;31327:162:0:o;34120:394::-;34385:7;34417:89;34431:5;34438:7;34447:10;34459:12;34473:17;34492:13;34417;:89::i;:::-;34410:96;34120:394;-1:-1:-1;;;;;;;34120:394:0:o;1333:38:56:-;;;-1:-1:-1;;;1333:38:56;;;;;:::o;2300:925::-;2417:5;;-1:-1:-1;;;;;2417:5:56;2403:10;:19;;:50;;-1:-1:-1;2427:26:56;;-1:-1:-1;;;2427:26:56;;;;2426:27;2403:50;2395:80;;;;;-1:-1:-1;;;2395:80:56;;;;;;;;;;;;-1:-1:-1;;;2395:80:56;;;;;;;;;;;;;;;2530:29;2580:28;-1:-1:-1;;;2580:9:56;:28::i;:::-;2721:8;;2530:79;;-1:-1:-1;;;;;;2706:23:56;;;2721:8;;2706:23;;;;:61;;-1:-1:-1;;;;;;2733:34:56;;;;2706:61;2698:94;;;;;-1:-1:-1;;;2698:94:56;;;;;;;;;;;;-1:-1:-1;;;2698:94:56;;;;;;;;;;;;;;;2959:1;-1:-1:-1;;;;;2907:54:56;:11;-1:-1:-1;;;;;2907:21:56;;-1:-1:-1;;;2907:40:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;2907:40:56;-1:-1:-1;;;;;2907:54:56;;;2899:87;;;;;-1:-1:-1;;;2899:87:56;;;;;;;;;;;;-1:-1:-1;;;2899:87:56;;;;;;;;;;;;;;;3093:8;;;3078:12;:23;;-1:-1:-1;;;;;3093:8:56;;;-1:-1:-1;;;;;;3078:23:56;;;;;;;3195:22;;;;;;;;;;;2300:925::o;31842:359:0:-;32074:7;32106:87;32120:5;32127:7;32136:10;32156:1;32160:17;32179:13;32106;:87::i;:::-;32099:94;31842:359;-1:-1:-1;;;;;;31842:359:0:o;2530:38::-;;;;:::o;1196:290:62:-;726:12:57;:10;:12::i;:::-;1370:6:62::1;594:23:64;608:8;594:13;:23::i;:::-;1401:3:62::2;594:23:64;608:8;594:13;:23::i;:::-;1423:3:62::3;948:18:64;957:8;948;:18::i;:::-;1444:34:62::4;1457:6;1465:3;1470:7;1444:12;:34::i;:::-;628:1:64::3;::::2;749::57::1;1196:290:62::0;;;:::o;1243:37:56:-;;;-1:-1:-1;;;;;1243:37:56;;:::o;1422:217:57:-;1498:8;;-1:-1:-1;;;;;1498:8:57;1484:10;:22;1476:52;;;;;-1:-1:-1;;;1476:52:57;;;;;;;;;;;;-1:-1:-1;;;1476:52:57;;;;;;;;;;;;;;;1563:8;;;1556:5;;1544:28;;-1:-1:-1;;;;;1563:8:57;;;;1556:5;;;;1544:28;;;1591:8;;;;1583:16;;-1:-1:-1;;;;;;1583:16:57;;;-1:-1:-1;;;;;1591:8:57;;1583:16;;;;1610:21;;;1422:217::o;1154:33:56:-;;;-1:-1:-1;;;;;1154:33:56;;:::o;5591:2853:0:-;5673:7;5693:14;5718:11;5740:14;5765:15;5791:13;5815:20;5846:22;5886:25;-1:-1:-1;;;5886:9:0;:25::i;:::-;5846:66;;5934:7;5925:16;;6049:1;6034:5;:12;:16;:41;;;;;6069:1;6054:5;:12;:16;;;;;;6074:1;6054:21;6034:41;6026:70;;;;;-1:-1:-1;;;6026:70:0;;;;;;;;;;;;-1:-1:-1;;;6026:70:0;;;;;;;;;;;;;;;6171:1;6154:2257;6178:5;:12;6174:1;:16;6154:2257;;;6215:23;6253:5;6263:1;6259;:5;6253:12;;;;;;;;;;;;;;6215:51;;6281:14;6298:5;6308:1;6304;:5;6298:12;;;;;;;;;;;;;;6281:29;;6325:23;6363:5;6369:1;6363:8;;;;;;;;;;;;;;6325:47;;6437:6;-1:-1:-1;;;;;6420:30:0;;:32;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;6420:32:0;;-1:-1:-1;6524:48:0;6420:32;6560:11;6524:24;:48::i;:::-;6510:62;;6601:48;6626:9;6637:11;6601:24;:48::i;:::-;6587:62;;6694:6;-1:-1:-1;;;;;6670:30:0;6678:11;-1:-1:-1;;;;;6670:30:0;;6666:1734;;;6817:1;6813;:5;:31;;;;6832:5;6842:1;6838;:5;6832:12;;;;;;;;;;;;;;-1:-1:-1;;;;;6822:22:0;:6;-1:-1:-1;;;;;6822:22:0;;;6813:31;6809:100;;;6888:6;-1:-1:-1;;;;;6876:31:0;;:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;6876:33:0;;-1:-1:-1;6809:100:0;6996:9;-1:-1:-1;;;;;6996:29:0;;7026:11;6996:42;;;;;;;;;;;;;-1:-1:-1;;;;;6996:42:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;6996:42:0;7076:33;;;-1:-1:-1;;;7076:33:0;;-1:-1:-1;;;;;7076:33:0;;;;;;;;;6996:42;;-1:-1:-1;7076:20:0;;;;;;:33;;;;;;;;;;;;;;;:20;:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;7076:33:0;;;;;;7137:61;;-1:-1:-1;;;7137:61:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7076:33;;-1:-1:-1;;;;;;7137:28:0;;;;;:61;;;;;;;;;;:28;:61;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;7137:61:0;7234:25;;;-1:-1:-1;;;7234:25:0;;;;7137:61;;-1:-1:-1;7223:57:0;;2119:7;;7223:37;;-1:-1:-1;;;;;7234:23:0;;;;;:25;;;;;7137:61;;7234:25;;;;;;;:23;:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;7234:25:0;7223:6;;:37;;;;;:10;:37;:::i;:::-;:41;;:57::i;:::-;7299:13;;;;;7217:63;-1:-1:-1;7415:18:0;:6;7299:13;7415:10;:18::i;:::-;7406:27;;6666:1734;;;7496:6;-1:-1:-1;;;;;7472:30:0;7480:11;-1:-1:-1;;;;;7472:30:0;;7468:932;;;7620:1;7616;:5;:31;;;;7635:5;7645:1;7641;:5;7635:12;;;;;;;;;;;;;;-1:-1:-1;;;;;7625:22:0;:6;-1:-1:-1;;;;;7625:22:0;;;7616:31;7612:100;;;7691:6;-1:-1:-1;;;;;7679:31:0;;:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;7679:33:0;;-1:-1:-1;7612:100:0;7799:9;-1:-1:-1;;;;;7799:29:0;;7829:11;7799:42;;;;;;;;;;;;;-1:-1:-1;;;;;7799:42:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;7799:42:0;7879:33;;;-1:-1:-1;;;7879:33:0;;-1:-1:-1;;;;;7879:33:0;;;;;;;;;7799:42;;-1:-1:-1;7879:20:0;;;;;;:33;;;;;;;;;;;;;;;:20;:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;7879:33:0;;;;;;7940:57;;-1:-1:-1;;;7940:57:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7879:33;;-1:-1:-1;;;;;;7940:24:0;;;;;:57;;;;;;;;;;:24;:57;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;7940:57:0;8033:25;;;-1:-1:-1;;;8033:25:0;;;;7940:57;;-1:-1:-1;8022:57:0;;2119:7;;8022:37;;-1:-1:-1;;;;;8033:23:0;;;;;:25;;;;;7940:57;;8033:25;;;;;;;:23;:25;;;;;;;;;;8022:57;8098:13;;;;;8016:63;-1:-1:-1;8214:18:0;:6;8098:13;8214:10;:18::i;7468:932::-;8330:54;8340:9;8351:11;8364;8377:6;8330:9;:54::i;:::-;8314:70;;-1:-1:-1;8314:70:0;-1:-1:-1;7468:932:0;-1:-1:-1;;;6197:1:0;6192:6;6154:2257;;;-1:-1:-1;8430:6:0;;-1:-1:-1;;;;;;;5591:2853:0;;;;;:::o;2606:48::-;;;;;;;;;;;;;;;:::o;15856:607::-;16026:7;16146:8;-1:-1:-1;;;;;16146:14:0;;:16;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;16146:16:0;16133:8;;-1:-1:-1;;;;;16121:41:0;;;;16133:5;;16139:1;;16133:8;;;;;;;;;;-1:-1:-1;;;;;16121:41:0;;16113:78;;;;;-1:-1:-1;;;16113:78:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;16260:14;16277:8;-1:-1:-1;;;;;16277:27:0;;16305:13;16320:10;16277:54;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;16277:54:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;16277:54:0;;-1:-1:-1;16386:69:0;16400:5;16277:54;16415:10;16427:12;16449:1;;16386:13;:69::i;219:29:57:-;;;-1:-1:-1;;;;;219:29:57;;:::o;32589:440:0:-;32900:7;32870:10;252:24:64;269:6;252:16;:24::i;:::-;32932:89:0::1;32946:5;32953:7;32962:10;32974:12;32988:17;33007:13;32932;:89::i;:::-;32925:96:::0;32589:440;-1:-1:-1;;;;;;;;32589:440:0:o;33806:240::-;33941:7;33968:70;33982:5;33989:7;33998:10;34010:12;34032:1;34036;33968:13;:70::i;:::-;33961:77;33806:240;-1:-1:-1;;;;;33806:240:0:o;3304:137:56:-;726:12:57;:10;:12::i;:::-;3421::56::1;::::0;3410:8:::1;:23:::0;;-1:-1:-1;;;;;;3410:23:56::1;-1:-1:-1::0;;;;;3421:12:56;;::::1;3410:23:::0;;;::::1;::::0;;3304:137::o;9608:1669:0:-;9934:7;580:12:59;:10;:12::i;:::-;603:6;:13;;-1:-1:-1;;;;603:13:59;-1:-1:-1;;;603:13:59;;;9904:10:0;252:24:64::1;9904:10:0::0;252:16:64::1;:24::i;:::-;10088:1:0::2;10073:5;:12;:16;:41;;;;;10108:1;10093:5;:12;:16;;;;;;10113:1;10093:21;10073:41;10065:70;;;::::0;;-1:-1:-1;;;10065:70:0;;::::2;;::::0;::::2;::::0;::::2;::::0;;;;-1:-1:-1;;;10065:70:0;;;;;;;;;;;;;::::2;;10227:77;10257:5;10263:1;10257:8;;;;;;;;;;;;;;10285:5;10291:1;10285:8;;;;;;;;;;;;;;10296:7;10227:17;:77::i;:::-;10363:24;-1:-1:-1::0;;;;;10410:40:0;::::2;10406:303;;10475:18:::0;;10467:56:::2;;;::::0;;-1:-1:-1;;;10467:56:0;;::::2;;::::0;::::2;::::0;::::2;::::0;;;;-1:-1:-1;;;10467:56:0;;;;;;;;;;;;;::::2;;10406:303;;;10577:13;10573:1;:17;:53;;;;;10611:15;;10594:13;:32;;10573:53;10565:91;;;::::0;;-1:-1:-1;;;10565:91:0;;::::2;;::::0;::::2;::::0;::::2;::::0;;;;-1:-1:-1;;;10565:91:0;;;;;;;;;;;;;::::2;;-1:-1:-1::0;10693:4:0::2;10406:303;10791:10;-1:-1:-1::0;;;;;10816:26:0;::::2;::::0;10812:71:::2;;-1:-1:-1::0;10871:12:0;10812:71:::2;10945:28;10976:61;10997:5;11004:11;11017:19;10976:20;:61::i;:::-;10945:92;;11048:14;11065:73;11078:4;11084:7;11093:10;11105:17;11124:13;11065:12;:73::i;:::-;11048:90;;11199:44;11217:4;11223:6;11231:11;11199:17;:44::i;:::-;639:6:59::0;:14;;-1:-1:-1;;;;639:14:59;;;11263:6:0;9608:1669;-1:-1:-1;;;;;;;;;;;9608:1669:0:o;12269:407::-;12534:7;12566:102;12576:5;12583:7;12592:10;12604:17;12623:14;12639:13;12662:1;12666;12566:9;:102::i;33103:205::-;33205:7;33232:68;33246:5;33253:7;33262:10;33282:1;33294;33298;33232:13;:68::i;:::-;33225:75;33103:205;-1:-1:-1;;;;33103:205:0:o;13781:1124::-;14152:7;14122:10;252:24:64;269:6;252:16;:24::i;:::-;14177:23:0::1;14215:5;14236:1;14221:5;:12;:16;14215:23;;;;;;;;;;;;;;14177:62;;14250:16;14278:19;-1:-1:-1::0;;;14278:9:0::1;:19::i;:::-;14250:48;;14399:20;-1:-1:-1::0;;;14399:9:0::1;:20::i;:::-;-1:-1:-1::0;;;;;14372:48:0::1;:11;-1:-1:-1::0;;;;;14372:48:0::1;;14364:85;;;::::0;;-1:-1:-1;;;14364:85:0;;::::1;;::::0;::::1;::::0;::::1;::::0;;;;::::1;::::0;;;;;;;;;;;;;::::1;;14511:14;14528:99;14542:5;14549:7;14558:10;14586:4;14594:17;14613:13;14528;:99::i;:::-;14511:116;;14676:54;14692:11;14713:7;14723:6;14676:15;:54::i;:::-;14796:75;::::0;;-1:-1:-1;;;14796:75:0;;::::1;::::0;::::1;::::0;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;14796:17:0;::::1;::::0;::::1;::::0;:75;;;;;-1:-1:-1;;14796:75:0;;;;;;;-1:-1:-1;14796:17:0;:75;::::1;;::::0;::::1;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;-1:-1:-1::0;14891:6:0;;13781:1124;-1:-1:-1;;;;;;;;;;;;;;;13781:1124:0:o;255:23:57:-;;;-1:-1:-1;;;;;255:23:57;;:::o;4906:290:0:-;5003:16;5032:32;5089:33;-1:-1:-1;;;5089:9:0;:33::i;:::-;5032:91;;5141:10;-1:-1:-1;;;;;5141:19:0;;5161:12;5175;5141:47;;;;;;;;;;;;;-1:-1:-1;;;;;5141:47:0;;;;;;-1:-1:-1;;;;;5141:47:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;5141:47:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;5141:47:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;5141:47:0;;;;;;;;;;;;-1:-1:-1;5141:47:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5134:54;;;4906:290;;;;:::o;1164:167:57:-;726:12;:10;:12::i;:::-;1268:5:::1;::::0;-1:-1:-1;;;;;1255:18:57;;::::1;1268:5:::0;::::1;1255:18;;1247:45;;;::::0;;-1:-1:-1;;;1247:45:57;;::::1;;::::0;::::1;::::0;::::1;::::0;;;;-1:-1:-1;;;1247:45:57;;;;;;;;;;;;;::::1;;1303:8;:20:::0;;-1:-1:-1;;;;;;1303:20:57::1;-1:-1:-1::0;;;;;1303:20:57;;;::::1;::::0;;;::::1;::::0;;1164:167::o;3841:230:0:-;726:12:57;:10;:12::i;:::-;2119:7:0::1;3954:16;:34;;3946:72;;;::::0;;-1:-1:-1;;;3946:72:0;;::::1;;::::0;::::1;::::0;::::1;::::0;;;;-1:-1:-1;;;3946:72:0;;;;;;;;;;;;;::::1;;4029:15;:34:::0;3841:230::o;813:104:57:-;882:5;;-1:-1:-1;;;;;882:5:57;868:10;:19;860:49;;;;;-1:-1:-1;;;860:49:57;;;;;;;;;;;;-1:-1:-1;;;860:49:57;;;;;;;;;;;;;;;813:104::o;692:128:64:-;-1:-1:-1;;;;;766:22:64;;758:54;;;;;-1:-1:-1;;;758:54:64;;;;;;;;;;;;-1:-1:-1;;;758:54:64;;;;;;;;;;;;;;;692:128;:::o;1041:126::-;-1:-1:-1;;;;;1110:25:64;;1130:4;1110:25;;1102:57;;;;;-1:-1:-1;;;1102:57:64;;;;;;;;;;;;-1:-1:-1;;;1102:57:64;;;;;;;;;;;;;;4077:133:56;4169:8;;:33;;;-1:-1:-1;;;4169:33:56;;;;;;;;;;4142:7;;-1:-1:-1;;;;;4169:8:56;;:18;;:33;;;;;;;;;;;;;;:8;:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;4169:33:56;;-1:-1:-1;4077:133:56;;;;:::o;1485:312:61:-;1631:59;;;-1:-1:-1;;;;;1631:59:61;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;1631:59:61;-1:-1:-1;;;1631:59:61;;;1610:81;;;;1575:12;;1589:17;;1610:20;;;;1631:59;1610:81;;;1631:59;1610:81;;1631:59;1610:81;;;;;;;;;;-1:-1:-1;;1610:81:61;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1574:117;;;;1709:7;:57;;;;-1:-1:-1;1721:11:61;;:16;;:44;;;1752:4;1741:24;;;;;;;;;;;;;;;-1:-1:-1;1741:24:61;1721:44;1701:89;;;;;-1:-1:-1;;;1701:89:61;;;;;;;;;;;;-1:-1:-1;;;1701:89:61;;;;;;;;;;;;;;;1485:312;;;;;:::o;29362:336:0:-;-1:-1:-1;;;;;29490:19:0;;29461:11;29490:19;;;:11;:19;;;;;;;;29485:52;;-1:-1:-1;29531:6:0;29524:13;;29485:52;29554:34;29577:10;29554:22;:34::i;:::-;29550:79;;;-1:-1:-1;2196:42:0;29603:26;;29550:79;29649:41;29679:10;29649:29;:41::i;:::-;29642:48;29362:336;-1:-1:-1;;;29362:336:0:o;1149:250:60:-;1209:7;1262;1258:34;;-1:-1:-1;1291:1:60;1284:8;;1258:34;1317:7;;;1322:2;1317;:7;:2;1343:6;;;;;:12;1335:37;;;;;-1:-1:-1;;;1335:37:60;;;;;;;;;;;;-1:-1:-1;;;1335:37:60;;;;;;;;;;;;;;1627:174;1687:7;1720:1;1715:2;:6;1707:37;;;;;-1:-1:-1;;;1707:37:60;;;;;;;;;;;;-1:-1:-1;;;1707:37:60;;;;;;;;;;;;;;;1755:9;1772:2;1767;:7;;;;;;;1627:174;-1:-1:-1;;;;1627:174:60:o;386:169::-;446:7;478;;;504;;;;496:32;;;;;-1:-1:-1;;;496:32:60;;;;;;;;;;;;-1:-1:-1;;;496:32:60;;;;;;;;;;;;;;778:147;838:7;872:2;866;:8;;858:34;;;;;-1:-1:-1;;;858:34:60;;;;;;;;;;;;-1:-1:-1;;;858:34:60;;;;;;;;;;;;;;;-1:-1:-1;910:7:60;;;778:147::o;29889:670:0:-;30067:85;;;-1:-1:-1;;;;;30067:85:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;30067:85:0;-1:-1:-1;;;30067:85:0;;;30205:31;;;;30018:7;;;;30067:85;30018:7;;30047:17;;30205:25;;;;30067:85;;30205:31;;30067:85;30205:31;;30067:85;30205:31;;;;;;;;;;-1:-1:-1;;30205:31:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;30163:73;;;;30253:7;30249:277;;;30281:10;:17;30302:2;30281:23;30277:113;;;30343:10;30332:42;;;;;;;;;;;;;;;-1:-1:-1;30332:42:0;;;;;;;;;-1:-1:-1;30332:42:0;-1:-1:-1;30325:49:0;;-1:-1:-1;;;30325:49:0;30277:113;30410:10;:17;30431:2;30410:23;30406:109;;;30473:10;30462:33;;;;;;;;;;;;;;;-1:-1:-1;30462:33:0;;-1:-1:-1;30497:1:0;;-1:-1:-1;30454:45:0;;-1:-1:-1;;;30454:45:0;30406:109;30546:1;30549;30538:13;;;;;;;29889:670;;;;;;;;:::o;351:112:64:-;435:1;426:6;:10;418:37;;;;;-1:-1:-1;;;418:37:64;;;;;;;;;;;;-1:-1:-1;;;418:37:64;;;;;;;;;;;;;;716:89:59;772:6;;-1:-1:-1;;;772:6:59;;;;771:7;763:34;;;;;-1:-1:-1;;;763:34:59;;;;;;;;;;;;-1:-1:-1;;;763:34:59;;;;;;;;;;;;;;20128:1710:0;20243:25;20290:7;-1:-1:-1;;;;;20290:13:0;;:15;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;20290:15:0;;-1:-1:-1;20318:21:0;20342:38;20290:15;20342:22;:38::i;:::-;20318:62;-1:-1:-1;20413:9:0;:13;20409:1422;;20499:7;20486:9;:20;20478:56;;;;;-1:-1:-1;;;20478:56:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;20769:16;20764:137;;20824:45;20854:14;20824:29;:45::i;:::-;-1:-1:-1;;;;;20804:75:0;;20888:9;20804:97;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;20764:137;20409:1422;;;-1:-1:-1;;;;;20955:25:0;;;;;;:11;:25;;;;;;;;20951:880;;;21167:66;21184:12;21198:10;21218:4;21225:7;21167:16;:66::i;:::-;21303:16;21299:91;;;21358:12;-1:-1:-1;;;;;21338:43:0;;21382:7;21338:52;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;20951:880;;;21605:16;21601:218;;;21640:76;21657:12;21671:10;21691:14;21708:7;21640:16;:76::i;21601:218::-;21753:66;21770:12;21784:10;21804:4;21811:7;21753:16;:66::i;23592:4261::-;23735:23;23771:28;23848:1;23823:15;:22;:26;;;;;;23802:48;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;23771:79;;23863:26;23908:20;23943;-1:-1:-1;;;23943:9:0;:20::i;:::-;23908:56;;24060:9;24080:1251;24121:1;24096:15;:22;:26;24092:1;:30;24080:1251;;;24147:23;24190:15;24206:1;24210;24206:5;24190:22;;;;;;;;;;;;;;24147:66;;24228:20;24270:6;-1:-1:-1;;;;;24270:12:0;;:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;24270:14:0;24339:22;;24270:14;;-1:-1:-1;24301:23:0;;24339:15;;24359:1;24355:5;;;24339:22;;;;;;;;;;;;24301:61;;24455:24;24482:20;:46;;;;;24507:21;24506:22;24482:46;:73;;;;;24547:8;-1:-1:-1;;;;;24532:23:0;:11;-1:-1:-1;;;;;24532:23:0;;24482:73;24455:100;;24574:19;24570:70;;;24636:4;24612:28;;24570:70;24671:648;;;;;;;;24834:9;-1:-1:-1;;;;;24671:648:0;;;;;24758:6;-1:-1:-1;;;;;24671:648:0;;;;;24938:15;24954:1;24938:18;;;;;;;;;;;;;;-1:-1:-1;;;;;24671:648:0;;;;;24989:11;-1:-1:-1;;;;;24671:648:0;;;;;25134:1;-1:-1:-1;;;;;24671:648:0;;;;;25211:33;25234:9;25211:22;:33::i;:::-;24671:648;;;;;;;;;;;;24657:4;24666:1;24662;:5;24657:11;;;;;;;;;;;;;:662;;;;24080:1251;;;;24129:1;24124:6;;;;24080:1251;;;25393:30;;:::i;:::-;25426:4;25431:1;25426:7;;;;;;;;;;;;;;;;;;;25460:20;;;;;-1:-1:-1;;;;;25448:33:0;;;;;:11;:33;;;;;;;25426:7;;-1:-1:-1;25448:33:0;;25444:472;;;25594:8;:31;;;25590:314;;;2196:42;25644:20;;;:42;25590:314;;;25885:18;;25855:49;;:29;:49::i;:::-;-1:-1:-1;;;;;25832:72:0;:20;;;:72;25590:314;25965:4;25984:1;25970:4;:11;:15;25965:21;;;;;;;;;;;;;;;;;;;26013:20;;;;-1:-1:-1;;;;;26001:33:0;;;;;:11;:33;;;;;;;;25965:21;;-1:-1:-1;26001:33:0;;25997:472;;;26147:8;:31;;;26143:314;;;2196:42;26197:20;;;:42;26143:314;;;26438:18;;26408:49;;:29;:49::i;:::-;-1:-1:-1;;;;;26385:72:0;:20;;;:72;26143:314;26536:1;26532:5;;26527:1295;26543:4;:11;26539:1;:15;26527:1295;;;26587:4;26592:1;26587:7;;;;;;;;;;;;;;26576:18;;26746:8;:31;;;26742:1069;;;26902:8;:28;;;26898:709;;;26992:4;26953:20;;;:45;26898:709;;;27125:1;27111:4;:11;:15;27106:1;:20;27102:505;;;-1:-1:-1;;;;;27149:35:0;;:20;;;:35;27102:505;;;27310:4;27315:1;27319;27315:5;27310:11;;;;;;;;;;;;;;:34;;;27306:301;;;27398:4;27403:1;27407;27403:5;27398:11;;;;;;;;;;;;;;;;;;:21;-1:-1:-1;;;;;27367:53:0;:20;;;:53;27306:301;;;27601:4;27562:20;;;:45;27306:301;26742:1069;;;27789:4;27750:20;;;:45;26742:1069;26556:3;;;;;26527:1295;;;-1:-1:-1;27841:4:0;;23592:4261;-1:-1:-1;;;;;;;23592:4261:0:o;17080:2701::-;17289:7;;17357;17289;17422:2194;17446:5;:12;17442:1;:16;17422:2194;;;17480:30;;:::i;:::-;17513:5;17519:1;17513:8;;;;;;;;;;;;;;17480:41;;17574:8;:31;;;17570:889;;;17820:6;;;;;:51;;;17866:4;-1:-1:-1;;;;;17830:41:0;:5;17840:1;17836;:5;17830:12;;;;;;;;;;;;;;:24;;;-1:-1:-1;;;;;17830:41:0;;17820:51;:89;;;;-1:-1:-1;17888:20:0;;;;;-1:-1:-1;;;;;17876:33:0;;;;;:11;:33;;;;;;17875:34;17820:89;17816:191;;;17932:75;17945:8;:20;;;17975:8;:18;;;17996:10;17932:12;:75::i;:::-;17570:889;;;18235:8;:15;;;-1:-1:-1;;;;;18191:61:0;:8;:20;;;-1:-1:-1;;;;;18191:61:0;;18187:272;;18365:78;18381:8;:20;;;18411:8;:18;;;18432:10;18365:15;:78::i;:::-;18514:8;:31;;;18509:564;;18600:18;;18628:20;;;;;18650;;;;18575:111;;-1:-1:-1;;;18575:111:0;;-1:-1:-1;;;;;18575:111:0;;;;;;;;;;;;;;;;;;;;18684:1;18575:111;;;;;;:52;;;;;:111;;;;;;;;;;;;;;;18600:18;18575:52;:111;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;18575:111:0;;-1:-1:-1;18509:564:0;;;18722:20;;;;;-1:-1:-1;;;;;18710:33:0;;;;;:11;:33;;;;;;18706:367;;;18773:18;;18820:20;;;;;18842;;;;18888;;;;18773:136;;-1:-1:-1;;;18773:136:0;;-1:-1:-1;;;;;18773:136:0;;;;;;;;;;;;;;;;;;;;18876:10;18773:136;;;;;;;;;;;;:26;;;;;18808:9;;18773:136;;;;;;;;;;;;;;18808:9;18773:26;:136;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;18706:367;18957:18;;18984:20;;;;;19006;;;;19052;;;;18957:116;;-1:-1:-1;;;18957:116:0;;-1:-1:-1;;;;;18957:116:0;;;;;;;;;;;;;;;;;;;;19040:10;18957:116;;;;;;;;;;;;:26;;;;;:116;;;;;;;;;;;;;;;:18;:26;:116;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;18957:116:0;;-1:-1:-1;18706:367:0;19138:8;:28;;;19134:308;;;19187:23;19213:47;2119:7;19213:27;:8;19226:13;19213:12;:27::i;:47::-;19187:73;;19287:8;:20;;;-1:-1:-1;;;;;19287:29:0;;19317:17;19336:15;19287:65;;;;;;;;;;;;;-1:-1:-1;;;;;19287:65:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;19287:65:0;19279:101;;;;;-1:-1:-1;;;19279:101:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;19399:27;;;;19134:308;19513:8;:20;;;-1:-1:-1;;;;;19463:105:0;19491:8;:20;;;-1:-1:-1;;;;;19463:105:0;19474:8;:15;;;-1:-1:-1;;;;;19463:105:0;;19535:10;19547:8;19557:10;19463:105;;;;;;;;;;;;;;-1:-1:-1;;;;;19463:105:0;;;;;;;;;;;;;;;;;-1:-1:-1;19596:8:0;;-1:-1:-1;17460:3:0;;17422:2194;;;;19712:10;19700:8;:22;;19692:53;;;;;-1:-1:-1;;;19692:53:0;;;;;;;;;;;;-1:-1:-1;;;19692:53:0;;;;;;;;;;;;;;;-1:-1:-1;19765:8:0;17080:2701;-1:-1:-1;;;;;;17080:2701:0:o;22182:893::-;22306:30;;:::i;:::-;22339:5;22360:1;22345:5;:12;:16;22339:23;;;;;;;;;;;;;;22306:56;;22476:4;-1:-1:-1;;;;;22444:37:0;:8;:20;;;-1:-1:-1;;;;;22444:37:0;;22440:63;;22496:7;;;22440:63;22541:20;;;;-1:-1:-1;;;;;22607:24:0;;22515:23;22607:24;;;:11;:24;;;;;;;;22603:465;;;22732:8;:31;;;22731:32;22724:40;;;;22889:11;-1:-1:-1;;;;;22869:44:0;;22914:12;22928:7;22869:67;;;;;;;;;;;;;-1:-1:-1;;;;;22869:67:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;22603:465;23008:48;23021:11;23034:12;23048:7;23008:12;:48::i;22182:893::-;;;;:::o;28319:348::-;28437:41;;;-1:-1:-1;;;28437:41:0;;28462:4;28437:41;;;;-1:-1:-1;;;;;28437:41:0;;;;;;;;;28417:17;;28437:16;;;;;:41;;;;;;;;;;;;;;:16;:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;28437:41:0;;-1:-1:-1;28493:18:0;;;28489:171;;;28532:13;;28528:68;;28564:32;28576:6;28584:8;28594:1;28564:11;:32::i;:::-;28611:37;28623:6;28631:8;28641:6;28611:11;:37::i;:::-;28319:348;;;;:::o;30833:420::-;30948:54;;;;;;;;;;;;;;;;-1:-1:-1;;;;;30948:54:0;-1:-1:-1;;;30948:54:0;;;31055:49;;;;30911:4;;;;30928:17;;-1:-1:-1;;;;;31055:30:0;;;31092:4;;30948:54;;31055:49;;;;;;30948:54;31055:49;;;;;;;;;;-1:-1:-1;;31055:49:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;31013:91;;;;31121:7;:34;;;;;31132:10;:17;31153:2;31132:23;31121:34;31117:104;;;31190:10;31179:30;;;;;;;;;;;;;;;-1:-1:-1;31179:30:0;;-1:-1:-1;31172:37:0;;-1:-1:-1;;;31172:37:0;31117:104;-1:-1:-1;31240:5:0;;30833:420;-1:-1:-1;;;;30833:420:0:o;28751:449::-;28835:11;28859:20;28882:10;-1:-1:-1;;;;;28882:30:0;;:32;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;28882:32:0;28859:55;;;-1:-1:-1;28930:9:0;28925:229;28949:12;28945:1;:16;28925:229;;;28983:31;29017:10;-1:-1:-1;;;;;29017:26:0;;29044:1;29017:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;29017:29:0;-1:-1:-1;;;;;29065:32:0;;;;;;:11;29017:29;29065:32;;;;;29017:29;;-1:-1:-1;29065:32:0;;29061:81;;;29123:19;-1:-1:-1;29116:26:0;;-1:-1:-1;;29116:26:0;29061:81;-1:-1:-1;28963:3:0;;28925:229;;;-1:-1:-1;2196:42:0;;28751:449;-1:-1:-1;;;28751:449:0:o;2190:348:61:-;2355:71;;;-1:-1:-1;;;;;2355:71:61;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;2355:71:61;-1:-1:-1;;;2355:71:61;;;2334:93;;;;2299:12;;2313:17;;2334:20;;;;2355:71;2334:93;;;2355:71;2334:93;;2355:71;2334:93;;;;;;;;;;-1:-1:-1;;2334:93:61;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2298:129;;;;2445:7;:57;;;;-1:-1:-1;2457:11:61;;:16;;:44;;;2488:4;2477:24;;;;;;;;;;;;;;;-1:-1:-1;2477:24:61;2457:44;2437:94;;;;;-1:-1:-1;;;2437:94:61;;;;;;;;;;;;;;;;;;;;;;;;;;;815:320;966:63;;;-1:-1:-1;;;;;966:63:61;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;966:63:61;-1:-1:-1;;;966:63:61;;;945:85;;;;910:12;;924:17;;945:20;;;;966:63;945:85;;;966:63;945:85;;966:63;945:85;;;;;;;;;;-1:-1:-1;;945:85:61;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;909:121;;;;1048:7;:57;;;;-1:-1:-1;1060:11:61;;:16;;:44;;;1091:4;1080:24;;;;;;;;;;;;;;;-1:-1:-1;1080:24:61;1060:44;1040:88;;;;;-1:-1:-1;;;1040:88:61;;;;;;;;;;;;-1:-1:-1;;;1040:88:61;;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o",
+ "source": "// SPDX-License-Identifier: SEE LICENSE IN LICENSE\r\npragma solidity 0.6.12;\r\nimport \"./IConversionPathFinder.sol\";\r\nimport \"./converter/interfaces/IConverter.sol\";\r\nimport \"./converter/interfaces/IConverterAnchor.sol\";\r\nimport \"./converter/interfaces/IBancorFormula.sol\";\r\nimport \"./utility/ContractRegistryClient.sol\";\r\nimport \"./utility/ReentrancyGuard.sol\";\r\nimport \"./utility/TokenHolder.sol\";\r\nimport \"./utility/SafeMath.sol\";\r\nimport \"./token/interfaces/IEtherToken.sol\";\r\nimport \"./token/interfaces/ISmartToken.sol\";\r\nimport \"./bancorx/interfaces/IBancorX.sol\";\r\n\r\n// interface of older converters for backward compatibility\r\ninterface ILegacyConverter {\r\n function change(IERC20Token _sourceToken, IERC20Token _targetToken, uint256 _amount, uint256 _minReturn) external returns (uint256);\r\n}\r\n\r\n/**\r\n * @dev The BancorNetwork contract is the main entry point for Bancor token conversions.\r\n * It also allows for the conversion of any token in the Bancor Network to any other token in a single\r\n * transaction by providing a conversion path.\r\n *\r\n * A note on Conversion Path: Conversion path is a data structure that is used when converting a token\r\n * to another token in the Bancor Network, when the conversion cannot necessarily be done by a single\r\n * converter and might require multiple 'hops'.\r\n * The path defines which converters should be used and what kind of conversion should be done in each step.\r\n *\r\n * The path format doesn't include complex structure; instead, it is represented by a single array\r\n * in which each 'hop' is represented by a 2-tuple - converter anchor & target token.\r\n * In addition, the first element is always the source token.\r\n * The converter anchor is only used as a pointer to a converter (since converter addresses are more\r\n * likely to change as opposed to anchor addresses).\r\n *\r\n * Format:\r\n * [source token, converter anchor, target token, converter anchor, target token...]\r\n*/\r\ncontract BancorNetwork is TokenHolder, ContractRegistryClient, ReentrancyGuard {\r\n using SafeMath for uint256;\r\n\r\n uint256 private constant PPM_RESOLUTION = 1000000;\r\n IERC20Token private constant ETH_RESERVE_ADDRESS = IERC20Token(0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE);\r\n\r\n struct ConversionStep {\r\n IConverter converter;\r\n IConverterAnchor anchor;\r\n IERC20Token sourceToken;\r\n IERC20Token targetToken;\r\n address payable beneficiary;\r\n bool isV28OrHigherConverter;\r\n bool processAffiliateFee;\r\n }\r\n\r\n uint256 public maxAffiliateFee = 30000; // maximum affiliate-fee\r\n\r\n mapping (IERC20Token => bool) public etherTokens; // list of all supported ether tokens\r\n\r\n /**\r\n * @dev triggered when a conversion between two tokens occurs\r\n *\r\n * @param _smartToken anchor governed by the converter\r\n * @param _fromToken source ERC20 token\r\n * @param _toToken target ERC20 token\r\n * @param _fromAmount amount converted, in the source token\r\n * @param _toAmount amount returned, minus conversion fee\r\n * @param _trader wallet that initiated the trade\r\n */\r\n event Conversion(\r\n IConverterAnchor indexed _smartToken,\r\n IERC20Token indexed _fromToken,\r\n IERC20Token indexed _toToken,\r\n uint256 _fromAmount,\r\n uint256 _toAmount,\r\n address _trader\r\n );\r\n\r\n /**\r\n * @dev initializes a new BancorNetwork instance\r\n *\r\n * @param _registry address of a contract registry contract\r\n */\r\n constructor(IContractRegistry _registry) ContractRegistryClient(_registry) public {\r\n etherTokens[ETH_RESERVE_ADDRESS] = true;\r\n }\r\n\r\n /**\r\n * @dev allows the owner to update the maximum affiliate-fee\r\n *\r\n * @param _maxAffiliateFee maximum affiliate-fee\r\n */\r\n function setMaxAffiliateFee(uint256 _maxAffiliateFee)\r\n public\r\n ownerOnly\r\n {\r\n require(_maxAffiliateFee <= PPM_RESOLUTION, \"ERR_INVALID_AFFILIATE_FEE\");\r\n maxAffiliateFee = _maxAffiliateFee;\r\n }\r\n\r\n /**\r\n * @dev allows the owner to register/unregister ether tokens\r\n *\r\n * @param _token ether token contract address\r\n * @param _register true to register, false to unregister\r\n */\r\n function registerEtherToken(IEtherToken _token, bool _register)\r\n public\r\n ownerOnly\r\n validAddress(address(_token))\r\n notThis(address(_token))\r\n {\r\n etherTokens[_token] = _register;\r\n }\r\n\r\n /**\r\n * @dev returns the conversion path between two tokens in the network\r\n * note that this method is quite expensive in terms of gas and should generally be called off-chain\r\n *\r\n * @param _sourceToken source token address\r\n * @param _targetToken target token address\r\n *\r\n * @return conversion path between the two tokens\r\n */\r\n function conversionPath(IERC20Token _sourceToken, IERC20Token _targetToken) public view returns (address[] memory) {\r\n IConversionPathFinder pathFinder = IConversionPathFinder(addressOf(CONVERSION_PATH_FINDER));\r\n return pathFinder.findPath(_sourceToken, _targetToken);\r\n }\r\n\r\n /**\r\n * @dev returns the expected target amount of converting a given amount on a given path\r\n * note that there is no support for circular paths\r\n *\r\n * @param _path conversion path (see conversion path format above)\r\n * @param _amount amount of _path[0] tokens received from the sender\r\n *\r\n * @return expected target amount\r\n */\r\n function rateByPath(address[] memory _path, uint256 _amount) public view returns (uint256) {\r\n uint256 amount;\r\n uint256 fee;\r\n uint256 supply;\r\n uint256 balance;\r\n uint32 weight;\r\n IConverter converter;\r\n IBancorFormula formula = IBancorFormula(addressOf(BANCOR_FORMULA));\r\n\r\n amount = _amount;\r\n\r\n // verify that the number of elements is larger than 2 and odd\r\n require(_path.length > 2 && _path.length % 2 == 1, \"ERR_INVALID_PATH\");\r\n\r\n // iterate over the conversion path\r\n for (uint256 i = 2; i < _path.length; i += 2) {\r\n IERC20Token sourceToken = IERC20Token(_path[i - 2]);\r\n address anchor = _path[i - 1];\r\n IERC20Token targetToken = IERC20Token(_path[i]);\r\n\r\n converter = IConverter(payable(IConverterAnchor(anchor).owner()));\r\n\r\n // backward compatibility\r\n sourceToken = getConverterTokenAddress(converter, sourceToken);\r\n targetToken = getConverterTokenAddress(converter, targetToken);\r\n\r\n if (address(targetToken) == anchor) { // buy the smart token\r\n // check if the current smart token has changed\r\n if (i < 3 || anchor != _path[i - 3])\r\n supply = ISmartToken(anchor).totalSupply();\r\n\r\n // get the amount & the conversion fee\r\n balance = converter.getConnectorBalance(sourceToken);\r\n (, weight, , , ) = converter.connectors(sourceToken);\r\n amount = formula.purchaseTargetAmount(supply, balance, weight, amount);\r\n fee = amount.mul(converter.conversionFee()).div(PPM_RESOLUTION);\r\n amount -= fee;\r\n\r\n // update the smart token supply for the next iteration\r\n supply = supply.add(amount);\r\n }\r\n else if (address(sourceToken) == anchor) { // sell the smart token\r\n // check if the current smart token has changed\r\n if (i < 3 || anchor != _path[i - 3])\r\n supply = ISmartToken(anchor).totalSupply();\r\n\r\n // get the amount & the conversion fee\r\n balance = converter.getConnectorBalance(targetToken);\r\n (, weight, , , ) = converter.connectors(targetToken);\r\n amount = formula.saleTargetAmount(supply, balance, weight, amount);\r\n fee = amount.mul(converter.conversionFee()).div(PPM_RESOLUTION);\r\n amount -= fee;\r\n\r\n // update the smart token supply for the next iteration\r\n supply = supply.sub(amount);\r\n }\r\n else { // cross reserve conversion\r\n (amount, fee) = getReturn(converter, sourceToken, targetToken, amount);\r\n }\r\n }\r\n\r\n return amount;\r\n }\r\n\r\n /**\r\n * @dev converts the token to any other token in the bancor network by following\r\n * a predefined conversion path and transfers the result tokens to a target account\r\n * affiliate account/fee can also be passed in to receive a conversion fee (on top of the liquidity provider fees)\r\n * note that the network should already have been given allowance of the source token (if not ETH)\r\n *\r\n * @param _path conversion path, see conversion path format above\r\n * @param _amount amount to convert from, in the source token\r\n * @param _minReturn if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero\r\n * @param _beneficiary account that will receive the conversion result or 0x0 to send the result to the sender account\r\n * @param _affiliateAccount wallet address to receive the affiliate fee or 0x0 to disable affiliate fee\r\n * @param _affiliateFee affiliate fee in PPM or 0 to disable affiliate fee\r\n *\r\n * @return amount of tokens received from the conversion\r\n */\r\n function convertByPath(\r\n address[] memory _path,\r\n uint256 _amount,\r\n uint256 _minReturn,\r\n address payable _beneficiary,\r\n address _affiliateAccount,\r\n uint256 _affiliateFee)\r\n public\r\n payable\r\n protected\r\n greaterThanZero(_minReturn)\r\n returns (uint256)\r\n {\r\n // verify that the path contrains at least a single 'hop' and that the number of elements is odd\r\n require(_path.length > 2 && _path.length % 2 == 1, \"ERR_INVALID_PATH\");\r\n\r\n // validate msg.value and prepare the source token for the conversion\r\n handleSourceToken(IERC20Token(_path[0]), IConverterAnchor(_path[1]), _amount);\r\n\r\n // check if affiliate fee is enabled\r\n bool affiliateFeeEnabled = false;\r\n if (address(_affiliateAccount) == address(0)) {\r\n require(_affiliateFee == 0, \"ERR_INVALID_AFFILIATE_FEE\");\r\n }\r\n else {\r\n require(0 < _affiliateFee && _affiliateFee <= maxAffiliateFee, \"ERR_INVALID_AFFILIATE_FEE\");\r\n affiliateFeeEnabled = true;\r\n }\r\n\r\n // check if beneficiary is set\r\n address payable beneficiary = msg.sender;\r\n if (_beneficiary != address(0))\r\n beneficiary = _beneficiary;\r\n\r\n // convert and get the resulting amount\r\n ConversionStep[] memory data = createConversionData(_path, beneficiary, affiliateFeeEnabled);\r\n uint256 amount = doConversion(data, _amount, _minReturn, _affiliateAccount, _affiliateFee);\r\n\r\n // handle the conversion target tokens\r\n handleTargetToken(data, amount, beneficiary);\r\n\r\n return amount;\r\n }\r\n\r\n /**\r\n * @dev converts any other token to BNT in the bancor network by following\r\n a predefined conversion path and transfers the result to an account on a different blockchain\r\n * note that the network should already have been given allowance of the source token (if not ETH)\r\n *\r\n * @param _path conversion path, see conversion path format above\r\n * @param _amount amount to convert from, in the source token\r\n * @param _minReturn if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero\r\n * @param _targetBlockchain blockchain BNT will be issued on\r\n * @param _targetAccount address/account on the target blockchain to send the BNT to\r\n * @param _conversionId pre-determined unique (if non zero) id which refers to this transaction\r\n *\r\n * @return the amount of BNT received from this conversion\r\n */\r\n function xConvert(\r\n address[] memory _path,\r\n uint256 _amount,\r\n uint256 _minReturn,\r\n bytes32 _targetBlockchain,\r\n bytes32 _targetAccount,\r\n uint256 _conversionId\r\n )\r\n public\r\n payable\r\n returns (uint256)\r\n {\r\n return xConvert2(_path, _amount, _minReturn, _targetBlockchain, _targetAccount, _conversionId, address(0), 0);\r\n }\r\n\r\n /**\r\n * @dev converts any other token to BNT in the bancor network by following\r\n a predefined conversion path and transfers the result to an account on a different blockchain\r\n * note that the network should already have been given allowance of the source token (if not ETH)\r\n *\r\n * @param _path conversion path, see conversion path format above\r\n * @param _amount amount to convert from, in the source token\r\n * @param _minReturn if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero\r\n * @param _targetBlockchain blockchain BNT will be issued on\r\n * @param _targetAccount address/account on the target blockchain to send the BNT to\r\n * @param _conversionId pre-determined unique (if non zero) id which refers to this transaction\r\n * @param _affiliateAccount affiliate account\r\n * @param _affiliateFee affiliate fee in PPM\r\n *\r\n * @return the amount of BNT received from this conversion\r\n */\r\n function xConvert2(\r\n address[] memory _path,\r\n uint256 _amount,\r\n uint256 _minReturn,\r\n bytes32 _targetBlockchain,\r\n bytes32 _targetAccount,\r\n uint256 _conversionId,\r\n address _affiliateAccount,\r\n uint256 _affiliateFee\r\n )\r\n public\r\n payable\r\n greaterThanZero(_minReturn)\r\n returns (uint256)\r\n {\r\n IERC20Token targetToken = IERC20Token(_path[_path.length - 1]);\r\n IBancorX bancorX = IBancorX(addressOf(BANCOR_X));\r\n\r\n // verify that the destination token is BNT\r\n require(targetToken == IERC20Token(addressOf(BNT_TOKEN)), \"ERR_INVALID_TARGET_TOKEN\");\r\n\r\n // convert and get the resulting amount\r\n uint256 amount = convertByPath(_path, _amount, _minReturn, payable(address(this)), _affiliateAccount, _affiliateFee);\r\n\r\n // grant BancorX allowance\r\n ensureAllowance(targetToken, address(bancorX), amount);\r\n\r\n // transfer the resulting amount to BancorX\r\n bancorX.xTransfer(_targetBlockchain, _targetAccount, amount, _conversionId);\r\n\r\n return amount;\r\n }\r\n\r\n /**\r\n * @dev allows a user to convert a token that was sent from another blockchain into any other\r\n * token on the BancorNetwork\r\n * ideally this transaction is created before the previous conversion is even complete, so\r\n * so the input amount isn't known at that point - the amount is actually take from the\r\n * BancorX contract directly by specifying the conversion id\r\n *\r\n * @param _path conversion path\r\n * @param _bancorX address of the BancorX contract for the source token\r\n * @param _conversionId pre-determined unique (if non zero) id which refers to this conversion\r\n * @param _minReturn if the conversion results in an amount smaller than the minimum return - it is cancelled, must be nonzero\r\n * @param _beneficiary wallet to receive the conversion result\r\n *\r\n * @return amount of tokens received from the conversion\r\n */\r\n function completeXConversion(address[] memory _path, IBancorX _bancorX, uint256 _conversionId, uint256 _minReturn, address payable _beneficiary)\r\n public returns (uint256)\r\n {\r\n // verify that the source token is the BancorX token\r\n require(IERC20Token(_path[0]) == _bancorX.token(), \"ERR_INVALID_SOURCE_TOKEN\");\r\n\r\n // get conversion amount from BancorX contract\r\n uint256 amount = _bancorX.getXTransferAmount(_conversionId, msg.sender);\r\n\r\n // perform the conversion\r\n return convertByPath(_path, amount, _minReturn, _beneficiary, address(0), 0);\r\n }\r\n\r\n /**\r\n * @dev executes the actual conversion by following the conversion path\r\n *\r\n * @param _data conversion data, see ConversionStep struct above\r\n * @param _amount amount to convert from, in the source token\r\n * @param _minReturn if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero\r\n * @param _affiliateAccount affiliate account\r\n * @param _affiliateFee affiliate fee in PPM\r\n *\r\n * @return amount of tokens received from the conversion\r\n */\r\n function doConversion(\r\n ConversionStep[] memory _data,\r\n uint256 _amount,\r\n uint256 _minReturn,\r\n address _affiliateAccount,\r\n uint256 _affiliateFee\r\n ) private returns (uint256) {\r\n uint256 toAmount;\r\n uint256 fromAmount = _amount;\r\n\r\n // iterate over the conversion data\r\n for (uint256 i = 0; i < _data.length; i++) {\r\n ConversionStep memory stepData = _data[i];\r\n\r\n // newer converter\r\n if (stepData.isV28OrHigherConverter) {\r\n // transfer the tokens to the converter only if the network contract currently holds the tokens\r\n // not needed with ETH or if it's the first conversion step\r\n if (i != 0 && _data[i - 1].beneficiary == address(this) && !etherTokens[stepData.sourceToken])\r\n safeTransfer(stepData.sourceToken, address(stepData.converter), fromAmount);\r\n }\r\n // older converter\r\n // if the source token is the smart token, no need to do any transfers as the converter controls it\r\n else if (stepData.sourceToken != ISmartToken(address(stepData.anchor))) {\r\n // grant allowance for it to transfer the tokens from the network contract\r\n ensureAllowance(stepData.sourceToken, address(stepData.converter), fromAmount);\r\n }\r\n\r\n // do the conversion\r\n if (!stepData.isV28OrHigherConverter)\r\n toAmount = ILegacyConverter(address(stepData.converter)).change(stepData.sourceToken, stepData.targetToken, fromAmount, 1);\r\n else if (etherTokens[stepData.sourceToken])\r\n toAmount = stepData.converter.convert{ value: msg.value }(stepData.sourceToken, stepData.targetToken, fromAmount, msg.sender, stepData.beneficiary);\r\n else\r\n toAmount = stepData.converter.convert(stepData.sourceToken, stepData.targetToken, fromAmount, msg.sender, stepData.beneficiary);\r\n\r\n // pay affiliate-fee if needed\r\n if (stepData.processAffiliateFee) {\r\n uint256 affiliateAmount = toAmount.mul(_affiliateFee).div(PPM_RESOLUTION);\r\n require(stepData.targetToken.transfer(_affiliateAccount, affiliateAmount), \"ERR_FEE_TRANSFER_FAILED\");\r\n toAmount -= affiliateAmount;\r\n }\r\n\r\n emit Conversion(stepData.anchor, stepData.sourceToken, stepData.targetToken, fromAmount, toAmount, msg.sender);\r\n fromAmount = toAmount;\r\n }\r\n\r\n // ensure the trade meets the minimum requested amount\r\n require(toAmount >= _minReturn, \"ERR_RETURN_TOO_LOW\");\r\n\r\n return toAmount;\r\n }\r\n\r\n /**\r\n * @dev validates msg.value and prepares the conversion source token for the conversion\r\n *\r\n * @param _sourceToken source token of the first conversion step\r\n * @param _anchor converter anchor of the first conversion step\r\n * @param _amount amount to convert from, in the source token\r\n */\r\n function handleSourceToken(IERC20Token _sourceToken, IConverterAnchor _anchor, uint256 _amount) private {\r\n IConverter firstConverter = IConverter(payable(_anchor.owner()));\r\n bool isNewerConverter = isV28OrHigherConverter(firstConverter);\r\n\r\n // ETH\r\n if (msg.value > 0) {\r\n // validate msg.value\r\n require(msg.value == _amount, \"ERR_ETH_AMOUNT_MISMATCH\");\r\n\r\n // EtherToken converter - deposit the ETH into the EtherToken\r\n // note that it can still be a non ETH converter if the path is wrong\r\n // but such conversion will simply revert\r\n if (!isNewerConverter)\r\n IEtherToken(address(getConverterEtherTokenAddress(firstConverter))).deposit{ value: msg.value }();\r\n }\r\n // EtherToken\r\n else if (etherTokens[_sourceToken]) {\r\n // claim the tokens - if the source token is ETH reserve, this call will fail\r\n // since in that case the transaction must be sent with msg.value\r\n safeTransferFrom(_sourceToken, msg.sender, address(this), _amount);\r\n\r\n // ETH converter - withdraw the ETH\r\n if (isNewerConverter)\r\n IEtherToken(address(_sourceToken)).withdraw(_amount);\r\n }\r\n // other ERC20 token\r\n else {\r\n // newer converter - transfer the tokens from the sender directly to the converter\r\n // otherwise claim the tokens\r\n if (isNewerConverter)\r\n safeTransferFrom(_sourceToken, msg.sender, address(firstConverter), _amount);\r\n else\r\n safeTransferFrom(_sourceToken, msg.sender, address(this), _amount);\r\n }\r\n }\r\n\r\n /**\r\n * @dev handles the conversion target token if the network still holds it at the end of the conversion\r\n *\r\n * @param _data conversion data, see ConversionStep struct above\r\n * @param _amount conversion target amount\r\n * @param _beneficiary wallet to receive the conversion result\r\n */\r\n function handleTargetToken(ConversionStep[] memory _data, uint256 _amount, address payable _beneficiary) private {\r\n ConversionStep memory stepData = _data[_data.length - 1];\r\n\r\n // network contract doesn't hold the tokens, do nothing\r\n if (stepData.beneficiary != address(this))\r\n return;\r\n\r\n IERC20Token targetToken = stepData.targetToken;\r\n\r\n // ETH / EtherToken\r\n if (etherTokens[targetToken]) {\r\n // newer converter should send ETH directly to the beneficiary\r\n assert(!stepData.isV28OrHigherConverter);\r\n\r\n // EtherToken converter - withdraw the ETH and transfer to the beneficiary\r\n IEtherToken(address(targetToken)).withdrawTo(_beneficiary, _amount);\r\n }\r\n // other ERC20 token\r\n else {\r\n safeTransfer(targetToken, _beneficiary, _amount);\r\n }\r\n }\r\n\r\n /**\r\n * @dev creates a memory cache of all conversion steps data to minimize logic and external calls during conversions\r\n *\r\n * @param _conversionPath conversion path, see conversion path format above\r\n * @param _beneficiary wallet to receive the conversion result\r\n * @param _affiliateFeeEnabled true if affiliate fee was requested by the sender, false if not\r\n *\r\n * @return cached conversion data to be ingested later on by the conversion flow\r\n */\r\n function createConversionData(address[] memory _conversionPath, address payable _beneficiary, bool _affiliateFeeEnabled) private view returns (ConversionStep[] memory) {\r\n ConversionStep[] memory data = new ConversionStep[](_conversionPath.length / 2);\r\n\r\n bool affiliateFeeProcessed = false;\r\n IERC20Token bntToken = IERC20Token(addressOf(BNT_TOKEN));\r\n // iterate the conversion path and create the conversion data for each step\r\n uint256 i;\r\n for (i = 0; i < _conversionPath.length - 1; i += 2) {\r\n IConverterAnchor anchor = IConverterAnchor(_conversionPath[i + 1]);\r\n IConverter converter = IConverter(payable(anchor.owner()));\r\n IERC20Token targetToken = IERC20Token(_conversionPath[i + 2]);\r\n\r\n // check if the affiliate fee should be processed in this step\r\n bool processAffiliateFee = _affiliateFeeEnabled && !affiliateFeeProcessed && targetToken == bntToken;\r\n if (processAffiliateFee)\r\n affiliateFeeProcessed = true;\r\n\r\n data[i / 2] = ConversionStep({\r\n // set the converter anchor\r\n anchor: anchor,\r\n\r\n // set the converter\r\n converter: converter,\r\n\r\n // set the source/target tokens\r\n sourceToken: IERC20Token(_conversionPath[i]),\r\n targetToken: targetToken,\r\n\r\n // requires knowledge about the next step, so initialize in the next phase\r\n beneficiary: address(0),\r\n\r\n // set flags\r\n isV28OrHigherConverter: isV28OrHigherConverter(converter),\r\n processAffiliateFee: processAffiliateFee\r\n });\r\n }\r\n\r\n // ETH support\r\n // source is ETH\r\n ConversionStep memory stepData = data[0];\r\n if (etherTokens[stepData.sourceToken]) {\r\n // newer converter - replace the source token address with ETH reserve address\r\n if (stepData.isV28OrHigherConverter)\r\n stepData.sourceToken = ETH_RESERVE_ADDRESS;\r\n // older converter - replace the source token with the EtherToken address used by the converter\r\n else\r\n stepData.sourceToken = getConverterEtherTokenAddress(stepData.converter);\r\n }\r\n\r\n // target is ETH\r\n stepData = data[data.length - 1];\r\n if (etherTokens[stepData.targetToken]) {\r\n // newer converter - replace the target token address with ETH reserve address\r\n if (stepData.isV28OrHigherConverter)\r\n stepData.targetToken = ETH_RESERVE_ADDRESS;\r\n // older converter - replace the target token with the EtherToken address used by the converter\r\n else\r\n stepData.targetToken = getConverterEtherTokenAddress(stepData.converter);\r\n }\r\n\r\n // set the beneficiary for each step\r\n for (i = 0; i < data.length; i++) {\r\n stepData = data[i];\r\n\r\n // first check if the converter in this step is newer as older converters don't even support the beneficiary argument\r\n if (stepData.isV28OrHigherConverter) {\r\n // if affiliate fee is processed in this step, beneficiary is the network contract\r\n if (stepData.processAffiliateFee)\r\n stepData.beneficiary = payable(address(this));\r\n // if it's the last step, beneficiary is the final beneficiary\r\n else if (i == data.length - 1)\r\n stepData.beneficiary = _beneficiary;\r\n // if the converter in the next step is newer, beneficiary is the next converter\r\n else if (data[i + 1].isV28OrHigherConverter)\r\n stepData.beneficiary = address(data[i + 1].converter);\r\n // the converter in the next step is older, beneficiary is the network contract\r\n else\r\n stepData.beneficiary = payable(address(this));\r\n }\r\n else {\r\n // converter in this step is older, beneficiary is the network contract\r\n stepData.beneficiary = payable(address(this));\r\n }\r\n }\r\n\r\n return data;\r\n }\r\n\r\n /**\r\n * @dev utility, checks whether allowance for the given spender exists and approves one if it doesn't.\r\n * Note that we use the non standard erc-20 interface in which `approve` has no return value so that\r\n * this function will work for both standard and non standard tokens\r\n *\r\n * @param _token token to check the allowance in\r\n * @param _spender approved address\r\n * @param _value allowance amount\r\n */\r\n function ensureAllowance(IERC20Token _token, address _spender, uint256 _value) private {\r\n uint256 allowance = _token.allowance(address(this), _spender);\r\n if (allowance < _value) {\r\n if (allowance > 0)\r\n safeApprove(_token, _spender, 0);\r\n safeApprove(_token, _spender, _value);\r\n }\r\n }\r\n\r\n // legacy - returns the address of an EtherToken used by the converter\r\n function getConverterEtherTokenAddress(IConverter _converter) private view returns (IERC20Token) {\r\n uint256 reserveCount = _converter.connectorTokenCount();\r\n for (uint256 i = 0; i < reserveCount; i++) {\r\n IERC20Token reserveTokenAddress = _converter.connectorTokens(i);\r\n if (etherTokens[reserveTokenAddress])\r\n return reserveTokenAddress;\r\n }\r\n\r\n return ETH_RESERVE_ADDRESS;\r\n }\r\n\r\n // legacy - if the token is an ether token, returns the ETH reserve address\r\n // used by the converter, otherwise returns the input token address\r\n function getConverterTokenAddress(IConverter _converter, IERC20Token _token) private view returns (IERC20Token) {\r\n if (!etherTokens[_token])\r\n return _token;\r\n\r\n if (isV28OrHigherConverter(_converter))\r\n return ETH_RESERVE_ADDRESS;\r\n\r\n return getConverterEtherTokenAddress(_converter);\r\n }\r\n\r\n bytes4 private constant GET_RETURN_FUNC_SELECTOR = bytes4(keccak256(\"getReturn(address,address,uint256)\"));\r\n\r\n // using a static call to get the return from older converters\r\n function getReturn(IConverter _dest, IERC20Token _sourceToken, IERC20Token _targetToken, uint256 _amount) internal view returns (uint256, uint256) {\r\n bytes memory data = abi.encodeWithSelector(GET_RETURN_FUNC_SELECTOR, _sourceToken, _targetToken, _amount);\r\n (bool success, bytes memory returnData) = address(_dest).staticcall(data);\r\n\r\n if (success) {\r\n if (returnData.length == 64) {\r\n return abi.decode(returnData, (uint256, uint256));\r\n }\r\n\r\n if (returnData.length == 32) {\r\n return (abi.decode(returnData, (uint256)), 0);\r\n }\r\n }\r\n\r\n return (0, 0);\r\n }\r\n\r\n bytes4 private constant IS_V28_OR_HIGHER_FUNC_SELECTOR = bytes4(keccak256(\"isV28OrHigher()\"));\r\n\r\n // using a static call to identify converter version\r\n // can't rely on the version number since the function had a different signature in older converters\r\n function isV28OrHigherConverter(IConverter _converter) internal view returns (bool) {\r\n bytes memory data = abi.encodeWithSelector(IS_V28_OR_HIGHER_FUNC_SELECTOR);\r\n (bool success, bytes memory returnData) = address(_converter).staticcall{ gas: 4000 }(data);\r\n\r\n if (success && returnData.length == 32) {\r\n return abi.decode(returnData, (bool));\r\n }\r\n\r\n return false;\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function getReturnByPath(address[] memory _path, uint256 _amount) public view returns (uint256, uint256) {\r\n return (rateByPath(_path, _amount), 0);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function convert(address[] memory _path, uint256 _amount, uint256 _minReturn) public payable returns (uint256) {\r\n return convertByPath(_path, _amount, _minReturn, address(0), address(0), 0);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function convert2(\r\n address[] memory _path,\r\n uint256 _amount,\r\n uint256 _minReturn,\r\n address _affiliateAccount,\r\n uint256 _affiliateFee\r\n )\r\n public\r\n payable\r\n returns (uint256)\r\n {\r\n return convertByPath(_path, _amount, _minReturn, address(0), _affiliateAccount, _affiliateFee);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function convertFor(address[] memory _path, uint256 _amount, uint256 _minReturn, address payable _beneficiary) public payable returns (uint256) {\r\n return convertByPath(_path, _amount, _minReturn, _beneficiary, address(0), 0);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function convertFor2(\r\n address[] memory _path,\r\n uint256 _amount,\r\n uint256 _minReturn,\r\n address payable _beneficiary,\r\n address _affiliateAccount,\r\n uint256 _affiliateFee\r\n )\r\n public\r\n payable\r\n greaterThanZero(_minReturn)\r\n returns (uint256)\r\n {\r\n return convertByPath(_path, _amount, _minReturn, _beneficiary, _affiliateAccount, _affiliateFee);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function claimAndConvert(address[] memory _path, uint256 _amount, uint256 _minReturn) public returns (uint256) {\r\n return convertByPath(_path, _amount, _minReturn, address(0), address(0), 0);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function claimAndConvert2(\r\n address[] memory _path,\r\n uint256 _amount,\r\n uint256 _minReturn,\r\n address _affiliateAccount,\r\n uint256 _affiliateFee\r\n )\r\n public\r\n returns (uint256)\r\n {\r\n return convertByPath(_path, _amount, _minReturn, address(0), _affiliateAccount, _affiliateFee);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function claimAndConvertFor(address[] memory _path, uint256 _amount, uint256 _minReturn, address payable _beneficiary) public returns (uint256) {\r\n return convertByPath(_path, _amount, _minReturn, _beneficiary, address(0), 0);\r\n }\r\n\r\n /**\r\n * @dev deprecated, backward compatibility\r\n */\r\n function claimAndConvertFor2(\r\n address[] memory _path,\r\n uint256 _amount,\r\n uint256 _minReturn,\r\n address payable _beneficiary,\r\n address _affiliateAccount,\r\n uint256 _affiliateFee\r\n )\r\n public\r\n returns (uint256)\r\n {\r\n return convertByPath(_path, _amount, _minReturn, _beneficiary, _affiliateAccount, _affiliateFee);\r\n }\r\n}\r\n",
+ "sourcePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/BancorNetwork.sol",
+ "ast": {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/BancorNetwork.sol",
+ "exportedSymbols": {
+ "BancorNetwork": [
+ 1976
+ ],
+ "ILegacyConverter": [
+ 26
+ ]
+ },
+ "id": 1977,
+ "license": "SEE LICENSE IN LICENSE",
+ "nodeType": "SourceUnit",
+ "nodes": [
+ {
+ "id": 1,
+ "literals": [
+ "solidity",
+ "0.6",
+ ".12"
+ ],
+ "nodeType": "PragmaDirective",
+ "src": "52:23:0"
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/IConversionPathFinder.sol",
+ "file": "./IConversionPathFinder.sol",
+ "id": 2,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 2547,
+ "src": "77:37:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IConverter.sol",
+ "file": "./converter/interfaces/IConverter.sol",
+ "id": 3,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 13341,
+ "src": "116:47:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IConverterAnchor.sol",
+ "file": "./converter/interfaces/IConverterAnchor.sol",
+ "id": 4,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 13350,
+ "src": "165:53:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IBancorFormula.sol",
+ "file": "./converter/interfaces/IBancorFormula.sol",
+ "id": 5,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 13178,
+ "src": "220:51:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/ContractRegistryClient.sol",
+ "file": "./utility/ContractRegistryClient.sol",
+ "id": 6,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 21720,
+ "src": "273:46:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/ReentrancyGuard.sol",
+ "file": "./utility/ReentrancyGuard.sol",
+ "id": 7,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 22243,
+ "src": "321:39:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/TokenHolder.sol",
+ "file": "./utility/TokenHolder.sol",
+ "id": 8,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 22576,
+ "src": "362:35:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/SafeMath.sol",
+ "file": "./utility/SafeMath.sol",
+ "id": 9,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 22355,
+ "src": "399:32:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/interfaces/IEtherToken.sol",
+ "file": "./token/interfaces/IEtherToken.sol",
+ "id": 10,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 21154,
+ "src": "433:44:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/interfaces/ISmartToken.sol",
+ "file": "./token/interfaces/ISmartToken.sol",
+ "id": 11,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 21183,
+ "src": "479:44:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/bancorx/interfaces/IBancorX.sol",
+ "file": "./bancorx/interfaces/IBancorX.sol",
+ "id": 12,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 3552,
+ "src": "525:43:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "abstract": false,
+ "baseContracts": [],
+ "contractDependencies": [],
+ "contractKind": "interface",
+ "documentation": null,
+ "fullyImplemented": false,
+ "id": 26,
+ "linearizedBaseContracts": [
+ 26
+ ],
+ "name": "ILegacyConverter",
+ "nodeType": "ContractDefinition",
+ "nodes": [
+ {
+ "body": null,
+ "documentation": null,
+ "functionSelector": "5e5144eb",
+ "id": 25,
+ "implemented": false,
+ "kind": "function",
+ "modifiers": [],
+ "name": "change",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 21,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 14,
+ "mutability": "mutable",
+ "name": "_sourceToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 25,
+ "src": "683:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 13,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "683:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 16,
+ "mutability": "mutable",
+ "name": "_targetToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 25,
+ "src": "709:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 15,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "709:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 18,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 25,
+ "src": "735:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 17,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "735:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 20,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 25,
+ "src": "752:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 19,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "752:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "682:89:0"
+ },
+ "returnParameters": {
+ "id": 24,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 23,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 25,
+ "src": "790:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 22,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "790:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "789:9:0"
+ },
+ "scope": 26,
+ "src": "667:132:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "external"
+ }
+ ],
+ "scope": 1977,
+ "src": "633:169:0"
+ },
+ {
+ "abstract": false,
+ "baseContracts": [
+ {
+ "arguments": null,
+ "baseName": {
+ "contractScope": null,
+ "id": 28,
+ "name": "TokenHolder",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 22575,
+ "src": "1982:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_TokenHolder_$22575",
+ "typeString": "contract TokenHolder"
+ }
+ },
+ "id": 29,
+ "nodeType": "InheritanceSpecifier",
+ "src": "1982:11:0"
+ },
+ {
+ "arguments": null,
+ "baseName": {
+ "contractScope": null,
+ "id": 30,
+ "name": "ContractRegistryClient",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21719,
+ "src": "1995:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_ContractRegistryClient_$21719",
+ "typeString": "contract ContractRegistryClient"
+ }
+ },
+ "id": 31,
+ "nodeType": "InheritanceSpecifier",
+ "src": "1995:22:0"
+ },
+ {
+ "arguments": null,
+ "baseName": {
+ "contractScope": null,
+ "id": 32,
+ "name": "ReentrancyGuard",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 22242,
+ "src": "2019:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_ReentrancyGuard_$22242",
+ "typeString": "contract ReentrancyGuard"
+ }
+ },
+ "id": 33,
+ "nodeType": "InheritanceSpecifier",
+ "src": "2019:15:0"
+ }
+ ],
+ "contractDependencies": [
+ 21719,
+ 21818,
+ 22242,
+ 22526,
+ 22575,
+ 22661,
+ 22847,
+ 22907
+ ],
+ "contractKind": "contract",
+ "documentation": {
+ "id": 27,
+ "nodeType": "StructuredDocumentation",
+ "src": "806:1148:0",
+ "text": " @dev The BancorNetwork contract is the main entry point for Bancor token conversions.\n It also allows for the conversion of any token in the Bancor Network to any other token in a single\n transaction by providing a conversion path.\n A note on Conversion Path: Conversion path is a data structure that is used when converting a token\n to another token in the Bancor Network, when the conversion cannot necessarily be done by a single\n converter and might require multiple 'hops'.\n The path defines which converters should be used and what kind of conversion should be done in each step.\n The path format doesn't include complex structure; instead, it is represented by a single array\n in which each 'hop' is represented by a 2-tuple - converter anchor & target token.\n In addition, the first element is always the source token.\n The converter anchor is only used as a pointer to a converter (since converter addresses are more\n likely to change as opposed to anchor addresses).\n Format:\n [source token, converter anchor, target token, converter anchor, target token...]"
+ },
+ "fullyImplemented": true,
+ "id": 1976,
+ "linearizedBaseContracts": [
+ 1976,
+ 22242,
+ 21719,
+ 22575,
+ 22661,
+ 21818,
+ 22526,
+ 22907,
+ 22847
+ ],
+ "name": "BancorNetwork",
+ "nodeType": "ContractDefinition",
+ "nodes": [
+ {
+ "id": 36,
+ "libraryName": {
+ "contractScope": null,
+ "id": 34,
+ "name": "SafeMath",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 22354,
+ "src": "2048:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_SafeMath_$22354",
+ "typeString": "library SafeMath"
+ }
+ },
+ "nodeType": "UsingForDirective",
+ "src": "2042:27:0",
+ "typeName": {
+ "id": 35,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "2061:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ },
+ {
+ "constant": true,
+ "id": 39,
+ "mutability": "constant",
+ "name": "PPM_RESOLUTION",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1976,
+ "src": "2077:49:0",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 37,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "2077:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "31303030303030",
+ "id": 38,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "2119:7:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1000000_by_1",
+ "typeString": "int_const 1000000"
+ },
+ "value": "1000000"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 44,
+ "mutability": "constant",
+ "name": "ETH_RESERVE_ADDRESS",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1976,
+ "src": "2133:106:0",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 40,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "2133:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "307845656565654565656545654565654565456545656545454565656565456565656565656545456545",
+ "id": 42,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "2196:42:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "value": "0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "id": 41,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "2184:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 43,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "2184:55:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "visibility": "private"
+ },
+ {
+ "canonicalName": "BancorNetwork.ConversionStep",
+ "id": 59,
+ "members": [
+ {
+ "constant": false,
+ "id": 46,
+ "mutability": "mutable",
+ "name": "converter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 59,
+ "src": "2281:20:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 45,
+ "name": "IConverter",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13340,
+ "src": "2281:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 48,
+ "mutability": "mutable",
+ "name": "anchor",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 59,
+ "src": "2312:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 47,
+ "name": "IConverterAnchor",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13349,
+ "src": "2312:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 50,
+ "mutability": "mutable",
+ "name": "sourceToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 59,
+ "src": "2346:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 49,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "2346:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 52,
+ "mutability": "mutable",
+ "name": "targetToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 59,
+ "src": "2380:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 51,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "2380:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 54,
+ "mutability": "mutable",
+ "name": "beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 59,
+ "src": "2414:27:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 53,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "2414:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 56,
+ "mutability": "mutable",
+ "name": "isV28OrHigherConverter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 59,
+ "src": "2452:27:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 55,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "2452:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 58,
+ "mutability": "mutable",
+ "name": "processAffiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 59,
+ "src": "2490:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 57,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "2490:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "name": "ConversionStep",
+ "nodeType": "StructDefinition",
+ "scope": 1976,
+ "src": "2248:274:0",
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "5d732ff2",
+ "id": 62,
+ "mutability": "mutable",
+ "name": "maxAffiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1976,
+ "src": "2530:38:0",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 60,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "2530:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "3330303030",
+ "id": 61,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "2563:5:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_30000_by_1",
+ "typeString": "int_const 30000"
+ },
+ "value": "30000"
+ },
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "8077ccf7",
+ "id": 66,
+ "mutability": "mutable",
+ "name": "etherTokens",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1976,
+ "src": "2606:48:0",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ },
+ "typeName": {
+ "id": 65,
+ "keyType": {
+ "contractScope": null,
+ "id": 63,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "2615:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "Mapping",
+ "src": "2606:29:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ },
+ "valueType": {
+ "id": 64,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "2630:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ }
+ },
+ "value": null,
+ "visibility": "public"
+ },
+ {
+ "anonymous": false,
+ "documentation": {
+ "id": 67,
+ "nodeType": "StructuredDocumentation",
+ "src": "2703:441:0",
+ "text": " @dev triggered when a conversion between two tokens occurs\n @param _smartToken anchor governed by the converter\n @param _fromToken source ERC20 token\n @param _toToken target ERC20 token\n @param _fromAmount amount converted, in the source token\n @param _toAmount amount returned, minus conversion fee\n @param _trader wallet that initiated the trade"
+ },
+ "id": 81,
+ "name": "Conversion",
+ "nodeType": "EventDefinition",
+ "parameters": {
+ "id": 80,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 69,
+ "indexed": true,
+ "mutability": "mutable",
+ "name": "_smartToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 81,
+ "src": "3177:36:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 68,
+ "name": "IConverterAnchor",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13349,
+ "src": "3177:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 71,
+ "indexed": true,
+ "mutability": "mutable",
+ "name": "_fromToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 81,
+ "src": "3224:30:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 70,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "3224:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 73,
+ "indexed": true,
+ "mutability": "mutable",
+ "name": "_toToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 81,
+ "src": "3265:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 72,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "3265:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 75,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_fromAmount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 81,
+ "src": "3304:19:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 74,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "3304:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 77,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_toAmount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 81,
+ "src": "3334:17:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 76,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "3334:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 79,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_trader",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 81,
+ "src": "3362:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 78,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "3362:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "3166:218:0"
+ },
+ "src": "3150:235:0"
+ },
+ {
+ "body": {
+ "id": 96,
+ "nodeType": "Block",
+ "src": "3625:58:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 94,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 90,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "3636:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 92,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 91,
+ "name": "ETH_RESERVE_ADDRESS",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 44,
+ "src": "3648:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "3636:32:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "74727565",
+ "id": 93,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "3671:4:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "true"
+ },
+ "src": "3636:39:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 95,
+ "nodeType": "ExpressionStatement",
+ "src": "3636:39:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 82,
+ "nodeType": "StructuredDocumentation",
+ "src": "3393:144:0",
+ "text": " @dev initializes a new BancorNetwork instance\n @param _registry address of a contract registry contract"
+ },
+ "id": 97,
+ "implemented": true,
+ "kind": "constructor",
+ "modifiers": [
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 87,
+ "name": "_registry",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 84,
+ "src": "3607:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IContractRegistry_$22831",
+ "typeString": "contract IContractRegistry"
+ }
+ }
+ ],
+ "id": 88,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 86,
+ "name": "ContractRegistryClient",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21719,
+ "src": "3584:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_ContractRegistryClient_$21719_$",
+ "typeString": "type(contract ContractRegistryClient)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "3584:33:0"
+ }
+ ],
+ "name": "",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 85,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 84,
+ "mutability": "mutable",
+ "name": "_registry",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 97,
+ "src": "3555:27:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IContractRegistry_$22831",
+ "typeString": "contract IContractRegistry"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 83,
+ "name": "IContractRegistry",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 22831,
+ "src": "3555:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IContractRegistry_$22831",
+ "typeString": "contract IContractRegistry"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "3554:29:0"
+ },
+ "returnParameters": {
+ "id": 89,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "3625:0:0"
+ },
+ "scope": 1976,
+ "src": "3543:140:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 116,
+ "nodeType": "Block",
+ "src": "3935:136:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 108,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 106,
+ "name": "_maxAffiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 100,
+ "src": "3954:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 107,
+ "name": "PPM_RESOLUTION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 39,
+ "src": "3974:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "3954:34:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f414646494c494154455f464545",
+ "id": 109,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "3990:27:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_5421a6ae0116cbc310697cd7899b77d6a7bc1fb10cd896c84c63fd20f8fbd382",
+ "typeString": "literal_string \"ERR_INVALID_AFFILIATE_FEE\""
+ },
+ "value": "ERR_INVALID_AFFILIATE_FEE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_5421a6ae0116cbc310697cd7899b77d6a7bc1fb10cd896c84c63fd20f8fbd382",
+ "typeString": "literal_string \"ERR_INVALID_AFFILIATE_FEE\""
+ }
+ ],
+ "id": 105,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "3946:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 110,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "3946:72:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 111,
+ "nodeType": "ExpressionStatement",
+ "src": "3946:72:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 114,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 112,
+ "name": "maxAffiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 62,
+ "src": "4029:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 113,
+ "name": "_maxAffiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 100,
+ "src": "4047:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "4029:34:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 115,
+ "nodeType": "ExpressionStatement",
+ "src": "4029:34:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 98,
+ "nodeType": "StructuredDocumentation",
+ "src": "3691:144:0",
+ "text": " @dev allows the owner to update the maximum affiliate-fee\n @param _maxAffiliateFee maximum affiliate-fee"
+ },
+ "functionSelector": "f3bc7d2a",
+ "id": 117,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [
+ {
+ "arguments": null,
+ "id": 103,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 102,
+ "name": "ownerOnly",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21754,
+ "src": "3920:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$__$",
+ "typeString": "modifier ()"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "3920:9:0"
+ }
+ ],
+ "name": "setMaxAffiliateFee",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 101,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 100,
+ "mutability": "mutable",
+ "name": "_maxAffiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 117,
+ "src": "3869:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 99,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "3869:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "3868:26:0"
+ },
+ "returnParameters": {
+ "id": 104,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "3935:0:0"
+ },
+ "scope": 1976,
+ "src": "3841:230:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 145,
+ "nodeType": "Block",
+ "src": "4474:50:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 143,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 139,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "4485:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 141,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 140,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 120,
+ "src": "4497:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4485:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 142,
+ "name": "_register",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 122,
+ "src": "4507:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "4485:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 144,
+ "nodeType": "ExpressionStatement",
+ "src": "4485:31:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 118,
+ "nodeType": "StructuredDocumentation",
+ "src": "4079:212:0",
+ "text": " @dev allows the owner to register/unregister ether tokens\n @param _token ether token contract address\n @param _register true to register, false to unregister"
+ },
+ "functionSelector": "02ef521e",
+ "id": 146,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [
+ {
+ "arguments": null,
+ "id": 125,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 124,
+ "name": "ownerOnly",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21754,
+ "src": "4386:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$__$",
+ "typeString": "modifier ()"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "4386:9:0"
+ },
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 129,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 120,
+ "src": "4426:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ ],
+ "id": 128,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "4418:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 127,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "4418:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 130,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "4418:15:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "id": 131,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 126,
+ "name": "validAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22618,
+ "src": "4405:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$_t_address_$",
+ "typeString": "modifier (address)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "4405:29:0"
+ },
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 135,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 120,
+ "src": "4460:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ ],
+ "id": 134,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "4452:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 133,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "4452:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 136,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "4452:15:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "id": 137,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 132,
+ "name": "notThis",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22644,
+ "src": "4444:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$_t_address_$",
+ "typeString": "modifier (address)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "4444:24:0"
+ }
+ ],
+ "name": "registerEtherToken",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 123,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 120,
+ "mutability": "mutable",
+ "name": "_token",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 146,
+ "src": "4325:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 119,
+ "name": "IEtherToken",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21153,
+ "src": "4325:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 122,
+ "mutability": "mutable",
+ "name": "_register",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 146,
+ "src": "4345:14:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 121,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "4345:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "4324:36:0"
+ },
+ "returnParameters": {
+ "id": 138,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "4474:0:0"
+ },
+ "scope": 1976,
+ "src": "4297:227:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 171,
+ "nodeType": "Block",
+ "src": "5021:175:0",
+ "statements": [
+ {
+ "assignments": [
+ 158
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 158,
+ "mutability": "mutable",
+ "name": "pathFinder",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 171,
+ "src": "5032:32:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConversionPathFinder_$2546",
+ "typeString": "contract IConversionPathFinder"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 157,
+ "name": "IConversionPathFinder",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 2546,
+ "src": "5032:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConversionPathFinder_$2546",
+ "typeString": "contract IConversionPathFinder"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 164,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 161,
+ "name": "CONVERSION_PATH_FINDER",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21539,
+ "src": "5099:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ ],
+ "id": 160,
+ "name": "addressOf",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21718,
+ "src": "5089:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$",
+ "typeString": "function (bytes32) view returns (address)"
+ }
+ },
+ "id": 162,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "5089:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 159,
+ "name": "IConversionPathFinder",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2546,
+ "src": "5067:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IConversionPathFinder_$2546_$",
+ "typeString": "type(contract IConversionPathFinder)"
+ }
+ },
+ "id": 163,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "5067:56:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConversionPathFinder_$2546",
+ "typeString": "contract IConversionPathFinder"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "5032:91:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 167,
+ "name": "_sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 149,
+ "src": "5161:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 168,
+ "name": "_targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 151,
+ "src": "5175:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 165,
+ "name": "pathFinder",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 158,
+ "src": "5141:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConversionPathFinder_$2546",
+ "typeString": "contract IConversionPathFinder"
+ }
+ },
+ "id": 166,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "findPath",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 2545,
+ "src": "5141:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_contract$_IERC20Token_$21127_$_t_contract$_IERC20Token_$21127_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
+ "typeString": "function (contract IERC20Token,contract IERC20Token) view external returns (address[] memory)"
+ }
+ },
+ "id": 169,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "5141:47:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "functionReturnParameters": 156,
+ "id": 170,
+ "nodeType": "Return",
+ "src": "5134:54:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 147,
+ "nodeType": "StructuredDocumentation",
+ "src": "4532:368:0",
+ "text": " @dev returns the conversion path between two tokens in the network\n note that this method is quite expensive in terms of gas and should generally be called off-chain\n @param _sourceToken source token address\n @param _targetToken target token address\n @return conversion path between the two tokens"
+ },
+ "functionSelector": "d734fa19",
+ "id": 172,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "conversionPath",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 152,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 149,
+ "mutability": "mutable",
+ "name": "_sourceToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 172,
+ "src": "4930:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 148,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "4930:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 151,
+ "mutability": "mutable",
+ "name": "_targetToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 172,
+ "src": "4956:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 150,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "4956:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "4929:52:0"
+ },
+ "returnParameters": {
+ "id": 156,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 155,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 172,
+ "src": "5003:16:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 153,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "5003:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 154,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "5003:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "5002:18:0"
+ },
+ "scope": 1976,
+ "src": "4906:290:0",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 461,
+ "nodeType": "Block",
+ "src": "5682:2762:0",
+ "statements": [
+ {
+ "assignments": [
+ 184
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 184,
+ "mutability": "mutable",
+ "name": "amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 461,
+ "src": "5693:14:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 183,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "5693:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 185,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "5693:14:0"
+ },
+ {
+ "assignments": [
+ 187
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 187,
+ "mutability": "mutable",
+ "name": "fee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 461,
+ "src": "5718:11:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 186,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "5718:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 188,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "5718:11:0"
+ },
+ {
+ "assignments": [
+ 190
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 190,
+ "mutability": "mutable",
+ "name": "supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 461,
+ "src": "5740:14:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 189,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "5740:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 191,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "5740:14:0"
+ },
+ {
+ "assignments": [
+ 193
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 193,
+ "mutability": "mutable",
+ "name": "balance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 461,
+ "src": "5765:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 192,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "5765:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 194,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "5765:15:0"
+ },
+ {
+ "assignments": [
+ 196
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 196,
+ "mutability": "mutable",
+ "name": "weight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 461,
+ "src": "5791:13:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 195,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "5791:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 197,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "5791:13:0"
+ },
+ {
+ "assignments": [
+ 199
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 199,
+ "mutability": "mutable",
+ "name": "converter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 461,
+ "src": "5815:20:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 198,
+ "name": "IConverter",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13340,
+ "src": "5815:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 200,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "5815:20:0"
+ },
+ {
+ "assignments": [
+ 202
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 202,
+ "mutability": "mutable",
+ "name": "formula",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 461,
+ "src": "5846:22:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorFormula_$13177",
+ "typeString": "contract IBancorFormula"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 201,
+ "name": "IBancorFormula",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13177,
+ "src": "5846:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorFormula_$13177",
+ "typeString": "contract IBancorFormula"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 208,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 205,
+ "name": "BANCOR_FORMULA",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21533,
+ "src": "5896:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ ],
+ "id": 204,
+ "name": "addressOf",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21718,
+ "src": "5886:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$",
+ "typeString": "function (bytes32) view returns (address)"
+ }
+ },
+ "id": 206,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "5886:25:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 203,
+ "name": "IBancorFormula",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 13177,
+ "src": "5871:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IBancorFormula_$13177_$",
+ "typeString": "type(contract IBancorFormula)"
+ }
+ },
+ "id": 207,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "5871:41:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorFormula_$13177",
+ "typeString": "contract IBancorFormula"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "5846:66:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 211,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 209,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "5925:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 210,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 178,
+ "src": "5934:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "5925:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 212,
+ "nodeType": "ExpressionStatement",
+ "src": "5925:16:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 224,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 217,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 214,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 176,
+ "src": "6034:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 215,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "6034:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 216,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6049:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "6034:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 223,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 221,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 218,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 176,
+ "src": "6054:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 219,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "6054:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "%",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 220,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6069:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "6054:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 222,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6074:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "6054:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "6034:41:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f50415448",
+ "id": 225,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6077:18:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_db637d0ca669449dd352e97481d5a38953b8126ef5f657bdd830d33ff33d5b16",
+ "typeString": "literal_string \"ERR_INVALID_PATH\""
+ },
+ "value": "ERR_INVALID_PATH"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_db637d0ca669449dd352e97481d5a38953b8126ef5f657bdd830d33ff33d5b16",
+ "typeString": "literal_string \"ERR_INVALID_PATH\""
+ }
+ ],
+ "id": 213,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "6026:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 226,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6026:70:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 227,
+ "nodeType": "ExpressionStatement",
+ "src": "6026:70:0"
+ },
+ {
+ "body": {
+ "id": 457,
+ "nodeType": "Block",
+ "src": "6200:2211:0",
+ "statements": [
+ {
+ "assignments": [
+ 241
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 241,
+ "mutability": "mutable",
+ "name": "sourceToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 457,
+ "src": "6215:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 240,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "6215:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 249,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 243,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 176,
+ "src": "6253:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 247,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 246,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 244,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "6259:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 245,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6263:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "6259:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "6253:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 242,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "6241:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 248,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6241:25:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "6215:51:0"
+ },
+ {
+ "assignments": [
+ 251
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 251,
+ "mutability": "mutable",
+ "name": "anchor",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 457,
+ "src": "6281:14:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 250,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "6281:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 257,
+ "initialValue": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 252,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 176,
+ "src": "6298:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 256,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 255,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 253,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "6304:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 254,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6308:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "6304:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "6298:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "6281:29:0"
+ },
+ {
+ "assignments": [
+ 259
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 259,
+ "mutability": "mutable",
+ "name": "targetToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 457,
+ "src": "6325:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 258,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "6325:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 265,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 261,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 176,
+ "src": "6363:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 263,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 262,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "6369:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "6363:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 260,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "6351:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 264,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6351:21:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "6325:47:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 277,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 266,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "6389:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 271,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 251,
+ "src": "6437:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 270,
+ "name": "IConverterAnchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 13349,
+ "src": "6420:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IConverterAnchor_$13349_$",
+ "typeString": "type(contract IConverterAnchor)"
+ }
+ },
+ "id": 272,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6420:24:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ "id": 273,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "owner",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22838,
+ "src": "6420:30:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_address_$",
+ "typeString": "function () view external returns (address)"
+ }
+ },
+ "id": 274,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6420:32:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 269,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "6412:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_payable_$",
+ "typeString": "type(address payable)"
+ },
+ "typeName": {
+ "id": 268,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "6412:8:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 275,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6412:41:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "id": 267,
+ "name": "IConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 13340,
+ "src": "6401:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IConverter_$13340_$",
+ "typeString": "type(contract IConverter)"
+ }
+ },
+ "id": 276,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6401:53:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "src": "6389:65:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 278,
+ "nodeType": "ExpressionStatement",
+ "src": "6389:65:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 284,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 279,
+ "name": "sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 241,
+ "src": "6510:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 281,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "6549:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 282,
+ "name": "sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 241,
+ "src": "6560:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "id": 280,
+ "name": "getConverterTokenAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1579,
+ "src": "6524:24:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$_t_contract$_IERC20Token_$21127_$returns$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "function (contract IConverter,contract IERC20Token) view returns (contract IERC20Token)"
+ }
+ },
+ "id": 283,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6524:48:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "6510:62:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "id": 285,
+ "nodeType": "ExpressionStatement",
+ "src": "6510:62:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 291,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 286,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 259,
+ "src": "6587:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 288,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "6626:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 289,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 259,
+ "src": "6637:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "id": 287,
+ "name": "getConverterTokenAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1579,
+ "src": "6601:24:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$_t_contract$_IERC20Token_$21127_$returns$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "function (contract IConverter,contract IERC20Token) view returns (contract IERC20Token)"
+ }
+ },
+ "id": 290,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6601:48:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "6587:62:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "id": 292,
+ "nodeType": "ExpressionStatement",
+ "src": "6587:62:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "id": 298,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 295,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 259,
+ "src": "6678:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "id": 294,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "6670:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 293,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "6670:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 296,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6670:20:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 297,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 251,
+ "src": "6694:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "src": "6670:30:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "id": 373,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 370,
+ "name": "sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 241,
+ "src": "7480:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "id": 369,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "7472:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 368,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "7472:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 371,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7472:20:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 372,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 251,
+ "src": "7496:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "src": "7472:30:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "id": 454,
+ "nodeType": "Block",
+ "src": "8267:133:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 452,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 443,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "8315:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 444,
+ "name": "fee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 187,
+ "src": "8323:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 445,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "8314:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 447,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "8340:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 448,
+ "name": "sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 241,
+ "src": "8351:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 449,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 259,
+ "src": "8364:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 450,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "8377:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 446,
+ "name": "getReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1664,
+ "src": "8330:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$_t_contract$_IERC20Token_$21127_$_t_contract$_IERC20Token_$21127_$_t_uint256_$returns$_t_uint256_$_t_uint256_$",
+ "typeString": "function (contract IConverter,contract IERC20Token,contract IERC20Token,uint256) view returns (uint256,uint256)"
+ }
+ },
+ "id": 451,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "8330:54:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "src": "8314:70:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 453,
+ "nodeType": "ExpressionStatement",
+ "src": "8314:70:0"
+ }
+ ]
+ },
+ "id": 455,
+ "nodeType": "IfStatement",
+ "src": "7468:932:0",
+ "trueBody": {
+ "id": 442,
+ "nodeType": "Block",
+ "src": "7504:744:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 384,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 376,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 374,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "7616:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "33",
+ "id": 375,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7620:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3_by_1",
+ "typeString": "int_const 3"
+ },
+ "value": "3"
+ },
+ "src": "7616:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "||",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "id": 383,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 377,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 251,
+ "src": "7625:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 378,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 176,
+ "src": "7635:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 382,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 381,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 379,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "7641:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "33",
+ "id": 380,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7645:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3_by_1",
+ "typeString": "int_const 3"
+ },
+ "value": "3"
+ },
+ "src": "7641:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "7635:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "src": "7625:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "7616:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 393,
+ "nodeType": "IfStatement",
+ "src": "7612:100:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 391,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 385,
+ "name": "supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 190,
+ "src": "7670:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 387,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 251,
+ "src": "7691:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 386,
+ "name": "ISmartToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21182,
+ "src": "7679:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_ISmartToken_$21182_$",
+ "typeString": "type(contract ISmartToken)"
+ }
+ },
+ "id": 388,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7679:19:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_ISmartToken_$21182",
+ "typeString": "contract ISmartToken"
+ }
+ },
+ "id": 389,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "totalSupply",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 21081,
+ "src": "7679:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_uint256_$",
+ "typeString": "function () view external returns (uint256)"
+ }
+ },
+ "id": 390,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7679:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "7670:42:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 392,
+ "nodeType": "ExpressionStatement",
+ "src": "7670:42:0"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 399,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 394,
+ "name": "balance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 193,
+ "src": "7789:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 397,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 259,
+ "src": "7829:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 395,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "7799:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 396,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "getConnectorBalance",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13327,
+ "src": "7799:29:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_contract$_IERC20Token_$21127_$returns$_t_uint256_$",
+ "typeString": "function (contract IERC20Token) view external returns (uint256)"
+ }
+ },
+ "id": 398,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7799:42:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "7789:52:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 400,
+ "nodeType": "ExpressionStatement",
+ "src": "7789:52:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 407,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ null,
+ {
+ "argumentTypes": null,
+ "id": 401,
+ "name": "weight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 196,
+ "src": "7863:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ null,
+ null,
+ null
+ ],
+ "id": 402,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "7860:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$_t_uint32_$__$__$__$",
+ "typeString": "tuple(,uint32,,,)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 405,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 259,
+ "src": "7900:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 403,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "7879:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 404,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "connectors",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13320,
+ "src": "7879:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_contract$_IERC20Token_$21127_$returns$_t_uint256_$_t_uint32_$_t_bool_$_t_bool_$_t_bool_$",
+ "typeString": "function (contract IERC20Token) view external returns (uint256,uint32,bool,bool,bool)"
+ }
+ },
+ "id": 406,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7879:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint32_$_t_bool_$_t_bool_$_t_bool_$",
+ "typeString": "tuple(uint256,uint32,bool,bool,bool)"
+ }
+ },
+ "src": "7860:52:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 408,
+ "nodeType": "ExpressionStatement",
+ "src": "7860:52:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 417,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 409,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "7931:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 412,
+ "name": "supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 190,
+ "src": "7965:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 413,
+ "name": "balance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 193,
+ "src": "7973:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 414,
+ "name": "weight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 196,
+ "src": "7982:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 415,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "7990:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 410,
+ "name": "formula",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 202,
+ "src": "7940:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorFormula_$13177",
+ "typeString": "contract IBancorFormula"
+ }
+ },
+ "id": 411,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "saleTargetAmount",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13105,
+ "src": "7940:24:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view external returns (uint256)"
+ }
+ },
+ "id": 416,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7940:57:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "7931:66:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 418,
+ "nodeType": "ExpressionStatement",
+ "src": "7931:66:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 429,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 419,
+ "name": "fee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 187,
+ "src": "8016:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 427,
+ "name": "PPM_RESOLUTION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 39,
+ "src": "8064:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "id": 422,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "8033:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 423,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "conversionFee",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13238,
+ "src": "8033:23:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_uint32_$",
+ "typeString": "function () view external returns (uint32)"
+ }
+ },
+ "id": 424,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "8033:25:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 420,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "8022:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 421,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "8022:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 425,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "8022:37:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 426,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "div",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22353,
+ "src": "8022:41:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 428,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "8022:57:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "8016:63:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 430,
+ "nodeType": "ExpressionStatement",
+ "src": "8016:63:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 433,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 431,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "8098:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 432,
+ "name": "fee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 187,
+ "src": "8108:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "8098:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 434,
+ "nodeType": "ExpressionStatement",
+ "src": "8098:13:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 440,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 435,
+ "name": "supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 190,
+ "src": "8205:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 438,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "8225:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 436,
+ "name": "supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 190,
+ "src": "8214:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 437,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sub",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22293,
+ "src": "8214:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 439,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "8214:18:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "8205:27:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 441,
+ "nodeType": "ExpressionStatement",
+ "src": "8205:27:0"
+ }
+ ]
+ }
+ },
+ "id": 456,
+ "nodeType": "IfStatement",
+ "src": "6666:1734:0",
+ "trueBody": {
+ "id": 367,
+ "nodeType": "Block",
+ "src": "6702:747:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 309,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 301,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 299,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "6813:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "33",
+ "id": 300,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6817:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3_by_1",
+ "typeString": "int_const 3"
+ },
+ "value": "3"
+ },
+ "src": "6813:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "||",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "id": 308,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 302,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 251,
+ "src": "6822:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 303,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 176,
+ "src": "6832:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 307,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 306,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 304,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "6838:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "33",
+ "id": 305,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6842:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3_by_1",
+ "typeString": "int_const 3"
+ },
+ "value": "3"
+ },
+ "src": "6838:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "6832:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "src": "6822:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "6813:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 318,
+ "nodeType": "IfStatement",
+ "src": "6809:100:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 316,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 310,
+ "name": "supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 190,
+ "src": "6867:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 312,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 251,
+ "src": "6888:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 311,
+ "name": "ISmartToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21182,
+ "src": "6876:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_ISmartToken_$21182_$",
+ "typeString": "type(contract ISmartToken)"
+ }
+ },
+ "id": 313,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6876:19:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_ISmartToken_$21182",
+ "typeString": "contract ISmartToken"
+ }
+ },
+ "id": 314,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "totalSupply",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 21081,
+ "src": "6876:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_uint256_$",
+ "typeString": "function () view external returns (uint256)"
+ }
+ },
+ "id": 315,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6876:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "6867:42:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 317,
+ "nodeType": "ExpressionStatement",
+ "src": "6867:42:0"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 324,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 319,
+ "name": "balance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 193,
+ "src": "6986:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 322,
+ "name": "sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 241,
+ "src": "7026:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 320,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "6996:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 321,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "getConnectorBalance",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13327,
+ "src": "6996:29:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_contract$_IERC20Token_$21127_$returns$_t_uint256_$",
+ "typeString": "function (contract IERC20Token) view external returns (uint256)"
+ }
+ },
+ "id": 323,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6996:42:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "6986:52:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 325,
+ "nodeType": "ExpressionStatement",
+ "src": "6986:52:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 332,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ null,
+ {
+ "argumentTypes": null,
+ "id": 326,
+ "name": "weight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 196,
+ "src": "7060:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ null,
+ null,
+ null
+ ],
+ "id": 327,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "7057:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$_t_uint32_$__$__$__$",
+ "typeString": "tuple(,uint32,,,)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 330,
+ "name": "sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 241,
+ "src": "7097:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 328,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "7076:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 329,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "connectors",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13320,
+ "src": "7076:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_contract$_IERC20Token_$21127_$returns$_t_uint256_$_t_uint32_$_t_bool_$_t_bool_$_t_bool_$",
+ "typeString": "function (contract IERC20Token) view external returns (uint256,uint32,bool,bool,bool)"
+ }
+ },
+ "id": 331,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7076:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint32_$_t_bool_$_t_bool_$_t_bool_$",
+ "typeString": "tuple(uint256,uint32,bool,bool,bool)"
+ }
+ },
+ "src": "7057:52:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 333,
+ "nodeType": "ExpressionStatement",
+ "src": "7057:52:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 342,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 334,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "7128:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 337,
+ "name": "supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 190,
+ "src": "7166:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 338,
+ "name": "balance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 193,
+ "src": "7174:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 339,
+ "name": "weight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 196,
+ "src": "7183:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 340,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "7191:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 335,
+ "name": "formula",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 202,
+ "src": "7137:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorFormula_$13177",
+ "typeString": "contract IBancorFormula"
+ }
+ },
+ "id": 336,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "purchaseTargetAmount",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13092,
+ "src": "7137:28:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view external returns (uint256)"
+ }
+ },
+ "id": 341,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7137:61:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "7128:70:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 343,
+ "nodeType": "ExpressionStatement",
+ "src": "7128:70:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 354,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 344,
+ "name": "fee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 187,
+ "src": "7217:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 352,
+ "name": "PPM_RESOLUTION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 39,
+ "src": "7265:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "id": 347,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "7234:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 348,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "conversionFee",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13238,
+ "src": "7234:23:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_uint32_$",
+ "typeString": "function () view external returns (uint32)"
+ }
+ },
+ "id": 349,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7234:25:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 345,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "7223:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 346,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "7223:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 350,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7223:37:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 351,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "div",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22353,
+ "src": "7223:41:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 353,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7223:57:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "7217:63:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 355,
+ "nodeType": "ExpressionStatement",
+ "src": "7217:63:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 358,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 356,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "7299:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 357,
+ "name": "fee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 187,
+ "src": "7309:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "7299:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 359,
+ "nodeType": "ExpressionStatement",
+ "src": "7299:13:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 365,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 360,
+ "name": "supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 190,
+ "src": "7406:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 363,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "7426:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 361,
+ "name": "supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 190,
+ "src": "7415:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 362,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "add",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22271,
+ "src": "7415:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 364,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7415:18:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "7406:27:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 366,
+ "nodeType": "ExpressionStatement",
+ "src": "7406:27:0"
+ }
+ ]
+ }
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 235,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 232,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "6174:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 233,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 176,
+ "src": "6178:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 234,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "6178:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "6174:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 458,
+ "initializationExpression": {
+ "assignments": [
+ 229
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 229,
+ "mutability": "mutable",
+ "name": "i",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 458,
+ "src": "6159:9:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 228,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "6159:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 231,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 230,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6171:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "6159:13:0"
+ },
+ "loopExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 238,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 236,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "6192:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 237,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6197:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "6192:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 239,
+ "nodeType": "ExpressionStatement",
+ "src": "6192:6:0"
+ },
+ "nodeType": "ForStatement",
+ "src": "6154:2257:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 459,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "8430:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 182,
+ "id": 460,
+ "nodeType": "Return",
+ "src": "8423:13:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 173,
+ "nodeType": "StructuredDocumentation",
+ "src": "5204:381:0",
+ "text": " @dev returns the expected target amount of converting a given amount on a given path\n note that there is no support for circular paths\n @param _path conversion path (see conversion path format above)\n @param _amount amount of _path[0] tokens received from the sender\n @return expected target amount"
+ },
+ "functionSelector": "7f9c0ecd",
+ "id": 462,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "rateByPath",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 179,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 176,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 462,
+ "src": "5611:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 174,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "5611:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 175,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "5611:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 178,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 462,
+ "src": "5635:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 177,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "5635:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "5610:41:0"
+ },
+ "returnParameters": {
+ "id": 182,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 181,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 462,
+ "src": "5673:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 180,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "5673:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "5672:9:0"
+ },
+ "scope": 1976,
+ "src": "5591:2853:0",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 597,
+ "nodeType": "Block",
+ "src": "9948:1329:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 497,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 490,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 487,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 466,
+ "src": "10073:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 488,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "10073:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 489,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10088:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "10073:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 496,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 494,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 491,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 466,
+ "src": "10093:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 492,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "10093:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "%",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 493,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10108:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "10093:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 495,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10113:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "10093:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "10073:41:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f50415448",
+ "id": 498,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10116:18:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_db637d0ca669449dd352e97481d5a38953b8126ef5f657bdd830d33ff33d5b16",
+ "typeString": "literal_string \"ERR_INVALID_PATH\""
+ },
+ "value": "ERR_INVALID_PATH"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_db637d0ca669449dd352e97481d5a38953b8126ef5f657bdd830d33ff33d5b16",
+ "typeString": "literal_string \"ERR_INVALID_PATH\""
+ }
+ ],
+ "id": 486,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "10065:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 499,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10065:70:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 500,
+ "nodeType": "ExpressionStatement",
+ "src": "10065:70:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 503,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 466,
+ "src": "10257:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 505,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 504,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10263:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "10257:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 502,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "10245:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 506,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10245:21:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 508,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 466,
+ "src": "10285:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 510,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 509,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10291:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "10285:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 507,
+ "name": "IConverterAnchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 13349,
+ "src": "10268:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IConverterAnchor_$13349_$",
+ "typeString": "type(contract IConverterAnchor)"
+ }
+ },
+ "id": 511,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10268:26:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 512,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 468,
+ "src": "10296:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 501,
+ "name": "handleSourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1110,
+ "src": "10227:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_contract$_IConverterAnchor_$13349_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,contract IConverterAnchor,uint256)"
+ }
+ },
+ "id": 513,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10227:77:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 514,
+ "nodeType": "ExpressionStatement",
+ "src": "10227:77:0"
+ },
+ {
+ "assignments": [
+ 516
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 516,
+ "mutability": "mutable",
+ "name": "affiliateFeeEnabled",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 597,
+ "src": "10363:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 515,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "10363:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 518,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "66616c7365",
+ "id": 517,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10390:5:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "false"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "10363:32:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "id": 527,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 521,
+ "name": "_affiliateAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 474,
+ "src": "10418:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 520,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "10410:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 519,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "10410:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 522,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10410:26:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 525,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10448:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 524,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "10440:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 523,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "10440:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 526,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10440:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "src": "10410:40:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "id": 551,
+ "nodeType": "Block",
+ "src": "10550:159:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 543,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 539,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 537,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10573:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 538,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 476,
+ "src": "10577:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "10573:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 542,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 540,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 476,
+ "src": "10594:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 541,
+ "name": "maxAffiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 62,
+ "src": "10611:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "10594:32:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "10573:53:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f414646494c494154455f464545",
+ "id": 544,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10628:27:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_5421a6ae0116cbc310697cd7899b77d6a7bc1fb10cd896c84c63fd20f8fbd382",
+ "typeString": "literal_string \"ERR_INVALID_AFFILIATE_FEE\""
+ },
+ "value": "ERR_INVALID_AFFILIATE_FEE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_5421a6ae0116cbc310697cd7899b77d6a7bc1fb10cd896c84c63fd20f8fbd382",
+ "typeString": "literal_string \"ERR_INVALID_AFFILIATE_FEE\""
+ }
+ ],
+ "id": 536,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "10565:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 545,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10565:91:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 546,
+ "nodeType": "ExpressionStatement",
+ "src": "10565:91:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 549,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 547,
+ "name": "affiliateFeeEnabled",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 516,
+ "src": "10671:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "74727565",
+ "id": 548,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10693:4:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "true"
+ },
+ "src": "10671:26:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 550,
+ "nodeType": "ExpressionStatement",
+ "src": "10671:26:0"
+ }
+ ]
+ },
+ "id": 552,
+ "nodeType": "IfStatement",
+ "src": "10406:303:0",
+ "trueBody": {
+ "id": 535,
+ "nodeType": "Block",
+ "src": "10452:83:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 531,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 529,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 476,
+ "src": "10475:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 530,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10492:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "10475:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f414646494c494154455f464545",
+ "id": 532,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10495:27:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_5421a6ae0116cbc310697cd7899b77d6a7bc1fb10cd896c84c63fd20f8fbd382",
+ "typeString": "literal_string \"ERR_INVALID_AFFILIATE_FEE\""
+ },
+ "value": "ERR_INVALID_AFFILIATE_FEE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_5421a6ae0116cbc310697cd7899b77d6a7bc1fb10cd896c84c63fd20f8fbd382",
+ "typeString": "literal_string \"ERR_INVALID_AFFILIATE_FEE\""
+ }
+ ],
+ "id": 528,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "10467:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 533,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10467:56:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 534,
+ "nodeType": "ExpressionStatement",
+ "src": "10467:56:0"
+ }
+ ]
+ }
+ },
+ {
+ "assignments": [
+ 554
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 554,
+ "mutability": "mutable",
+ "name": "beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 597,
+ "src": "10761:27:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 553,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "10761:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 557,
+ "initialValue": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 555,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "10791:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 556,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sender",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "10791:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "10761:40:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "id": 563,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 558,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 472,
+ "src": "10816:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 561,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10840:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 560,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "10832:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 559,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "10832:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 562,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10832:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "src": "10816:26:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 568,
+ "nodeType": "IfStatement",
+ "src": "10812:71:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 566,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 564,
+ "name": "beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 554,
+ "src": "10857:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 565,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 472,
+ "src": "10871:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "src": "10857:26:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "id": 567,
+ "nodeType": "ExpressionStatement",
+ "src": "10857:26:0"
+ }
+ },
+ {
+ "assignments": [
+ 572
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 572,
+ "mutability": "mutable",
+ "name": "data",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 597,
+ "src": "10945:28:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ },
+ "typeName": {
+ "baseType": {
+ "contractScope": null,
+ "id": 570,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "10945:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "id": 571,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "10945:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_storage_$dyn_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 578,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 574,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 466,
+ "src": "10997:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 575,
+ "name": "beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 554,
+ "src": "11004:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 576,
+ "name": "affiliateFeeEnabled",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 516,
+ "src": "11017:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ ],
+ "id": 573,
+ "name": "createConversionData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1468,
+ "src": "10976:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_array$_t_address_$dyn_memory_ptr_$_t_address_payable_$_t_bool_$returns$_t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr_$",
+ "typeString": "function (address[] memory,address payable,bool) view returns (struct BancorNetwork.ConversionStep memory[] memory)"
+ }
+ },
+ "id": 577,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10976:61:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "10945:92:0"
+ },
+ {
+ "assignments": [
+ 580
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 580,
+ "mutability": "mutable",
+ "name": "amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 597,
+ "src": "11048:14:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 579,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "11048:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 588,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 582,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 572,
+ "src": "11078:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 583,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 468,
+ "src": "11084:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 584,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 470,
+ "src": "11093:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 585,
+ "name": "_affiliateAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 474,
+ "src": "11105:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 586,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 476,
+ "src": "11124:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 581,
+ "name": "doConversion",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 998,
+ "src": "11065:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (struct BancorNetwork.ConversionStep memory[] memory,uint256,uint256,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 587,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "11065:73:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "11048:90:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 590,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 572,
+ "src": "11217:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 591,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 580,
+ "src": "11223:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 592,
+ "name": "beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 554,
+ "src": "11231:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "id": 589,
+ "name": "handleTargetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1174,
+ "src": "11199:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr_$_t_uint256_$_t_address_payable_$returns$__$",
+ "typeString": "function (struct BancorNetwork.ConversionStep memory[] memory,uint256,address payable)"
+ }
+ },
+ "id": 593,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "11199:44:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 594,
+ "nodeType": "ExpressionStatement",
+ "src": "11199:44:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 595,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 580,
+ "src": "11263:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 485,
+ "id": 596,
+ "nodeType": "Return",
+ "src": "11256:13:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 463,
+ "nodeType": "StructuredDocumentation",
+ "src": "8452:1150:0",
+ "text": " @dev converts the token to any other token in the bancor network by following\n a predefined conversion path and transfers the result tokens to a target account\n affiliate account/fee can also be passed in to receive a conversion fee (on top of the liquidity provider fees)\n note that the network should already have been given allowance of the source token (if not ETH)\n @param _path conversion path, see conversion path format above\n @param _amount amount to convert from, in the source token\n @param _minReturn if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero\n @param _beneficiary account that will receive the conversion result or 0x0 to send the result to the sender account\n @param _affiliateAccount wallet address to receive the affiliate fee or 0x0 to disable affiliate fee\n @param _affiliateFee affiliate fee in PPM or 0 to disable affiliate fee\n @return amount of tokens received from the conversion"
+ },
+ "functionSelector": "b77d239b",
+ "id": 598,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [
+ {
+ "arguments": null,
+ "id": 479,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 478,
+ "name": "protected",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22231,
+ "src": "9869:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$__$",
+ "typeString": "modifier ()"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "9869:9:0"
+ },
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 481,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 470,
+ "src": "9904:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 482,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 480,
+ "name": "greaterThanZero",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22595,
+ "src": "9888:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$_t_uint256_$",
+ "typeString": "modifier (uint256)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "9888:27:0"
+ }
+ ],
+ "name": "convertByPath",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 477,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 466,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 598,
+ "src": "9641:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 464,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "9641:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 465,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "9641:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 468,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 598,
+ "src": "9674:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 467,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "9674:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 470,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 598,
+ "src": "9700:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 469,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "9700:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 472,
+ "mutability": "mutable",
+ "name": "_beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 598,
+ "src": "9729:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 471,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "9729:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 474,
+ "mutability": "mutable",
+ "name": "_affiliateAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 598,
+ "src": "9768:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 473,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "9768:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 476,
+ "mutability": "mutable",
+ "name": "_affiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 598,
+ "src": "9804:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 475,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "9804:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "9630:196:0"
+ },
+ "returnParameters": {
+ "id": 485,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 484,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 598,
+ "src": "9934:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 483,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "9934:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "9933:9:0"
+ },
+ "scope": 1976,
+ "src": "9608:1669:0",
+ "stateMutability": "payable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 631,
+ "nodeType": "Block",
+ "src": "12548:128:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 618,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 602,
+ "src": "12576:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 619,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 604,
+ "src": "12583:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 620,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 606,
+ "src": "12592:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 621,
+ "name": "_targetBlockchain",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 608,
+ "src": "12604:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 622,
+ "name": "_targetAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 610,
+ "src": "12623:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 623,
+ "name": "_conversionId",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 612,
+ "src": "12639:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 626,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12662:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 625,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "12654:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 624,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "12654:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 627,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "12654:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 628,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12666:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 617,
+ "name": "xConvert2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 726,
+ "src": "12566:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_bytes32_$_t_bytes32_$_t_uint256_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,bytes32,bytes32,uint256,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 629,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "12566:102:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 616,
+ "id": 630,
+ "nodeType": "Return",
+ "src": "12559:109:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 599,
+ "nodeType": "StructuredDocumentation",
+ "src": "11285:978:0",
+ "text": " @dev converts any other token to BNT in the bancor network by following\na predefined conversion path and transfers the result to an account on a different blockchain\n note that the network should already have been given allowance of the source token (if not ETH)\n @param _path conversion path, see conversion path format above\n @param _amount amount to convert from, in the source token\n @param _minReturn if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero\n @param _targetBlockchain blockchain BNT will be issued on\n @param _targetAccount address/account on the target blockchain to send the BNT to\n @param _conversionId pre-determined unique (if non zero) id which refers to this transaction\n @return the amount of BNT received from this conversion"
+ },
+ "functionSelector": "c52173de",
+ "id": 632,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "xConvert",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 613,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 602,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 632,
+ "src": "12297:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 600,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "12297:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 601,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "12297:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 604,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 632,
+ "src": "12330:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 603,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "12330:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 606,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 632,
+ "src": "12356:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 605,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "12356:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 608,
+ "mutability": "mutable",
+ "name": "_targetBlockchain",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 632,
+ "src": "12385:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ "typeName": {
+ "id": 607,
+ "name": "bytes32",
+ "nodeType": "ElementaryTypeName",
+ "src": "12385:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 610,
+ "mutability": "mutable",
+ "name": "_targetAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 632,
+ "src": "12421:22:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ "typeName": {
+ "id": 609,
+ "name": "bytes32",
+ "nodeType": "ElementaryTypeName",
+ "src": "12421:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 612,
+ "mutability": "mutable",
+ "name": "_conversionId",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 632,
+ "src": "12454:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 611,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "12454:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "12286:196:0"
+ },
+ "returnParameters": {
+ "id": 616,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 615,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 632,
+ "src": "12534:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 614,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "12534:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "12533:9:0"
+ },
+ "scope": 1976,
+ "src": "12269:407:0",
+ "stateMutability": "payable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 725,
+ "nodeType": "Block",
+ "src": "14166:739:0",
+ "statements": [
+ {
+ "assignments": [
+ 659
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 659,
+ "mutability": "mutable",
+ "name": "targetToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 725,
+ "src": "14177:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 658,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "14177:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 668,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 661,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 636,
+ "src": "14215:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 666,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 665,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 662,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 636,
+ "src": "14221:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 663,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "14221:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 664,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14236:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "14221:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "14215:23:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 660,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "14203:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 667,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14203:36:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "14177:62:0"
+ },
+ {
+ "assignments": [
+ 670
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 670,
+ "mutability": "mutable",
+ "name": "bancorX",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 725,
+ "src": "14250:16:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 669,
+ "name": "IBancorX",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 3551,
+ "src": "14250:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 676,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 673,
+ "name": "BANCOR_X",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21554,
+ "src": "14288:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ ],
+ "id": 672,
+ "name": "addressOf",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21718,
+ "src": "14278:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$",
+ "typeString": "function (bytes32) view returns (address)"
+ }
+ },
+ "id": 674,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14278:19:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 671,
+ "name": "IBancorX",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3551,
+ "src": "14269:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IBancorX_$3551_$",
+ "typeString": "type(contract IBancorX)"
+ }
+ },
+ "id": 675,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14269:29:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "14250:48:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "id": 684,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 678,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 659,
+ "src": "14372:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 681,
+ "name": "BNT_TOKEN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21551,
+ "src": "14409:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ ],
+ "id": 680,
+ "name": "addressOf",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21718,
+ "src": "14399:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$",
+ "typeString": "function (bytes32) view returns (address)"
+ }
+ },
+ "id": 682,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14399:20:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 679,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "14387:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 683,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14387:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "14372:48:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f5441524745545f544f4b454e",
+ "id": 685,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14422:26:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_506dba30f9da1ed4da3626f556faadafab0575131908ae8223c813a59e0707f3",
+ "typeString": "literal_string \"ERR_INVALID_TARGET_TOKEN\""
+ },
+ "value": "ERR_INVALID_TARGET_TOKEN"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_506dba30f9da1ed4da3626f556faadafab0575131908ae8223c813a59e0707f3",
+ "typeString": "literal_string \"ERR_INVALID_TARGET_TOKEN\""
+ }
+ ],
+ "id": 677,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "14364:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 686,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14364:85:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 687,
+ "nodeType": "ExpressionStatement",
+ "src": "14364:85:0"
+ },
+ {
+ "assignments": [
+ 689
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 689,
+ "mutability": "mutable",
+ "name": "amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 725,
+ "src": "14511:14:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 688,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "14511:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 704,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 691,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 636,
+ "src": "14542:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 692,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 638,
+ "src": "14549:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 693,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 640,
+ "src": "14558:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 698,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "14586:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 697,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "14578:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 696,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "14578:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 699,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14578:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 695,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "14570:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_payable_$",
+ "typeString": "type(address payable)"
+ },
+ "typeName": {
+ "id": 694,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "14570:8:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 700,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14570:22:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 701,
+ "name": "_affiliateAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 648,
+ "src": "14594:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 702,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 650,
+ "src": "14613:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 690,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "14528:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 703,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14528:99:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "14511:116:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 706,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 659,
+ "src": "14692:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 709,
+ "name": "bancorX",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 670,
+ "src": "14713:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ }
+ ],
+ "id": 708,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "14705:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 707,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "14705:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 710,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14705:16:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 711,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 689,
+ "src": "14723:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 705,
+ "name": "ensureAllowance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1511,
+ "src": "14676:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,uint256)"
+ }
+ },
+ "id": 712,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14676:54:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 713,
+ "nodeType": "ExpressionStatement",
+ "src": "14676:54:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 717,
+ "name": "_targetBlockchain",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 642,
+ "src": "14814:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 718,
+ "name": "_targetAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 644,
+ "src": "14833:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 719,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 689,
+ "src": "14849:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 720,
+ "name": "_conversionId",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 646,
+ "src": "14857:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 714,
+ "name": "bancorX",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 670,
+ "src": "14796:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ }
+ },
+ "id": 716,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "xTransfer",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 3541,
+ "src": "14796:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_nonpayable$_t_bytes32_$_t_bytes32_$_t_uint256_$_t_uint256_$returns$__$",
+ "typeString": "function (bytes32,bytes32,uint256,uint256) external"
+ }
+ },
+ "id": 721,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14796:75:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 722,
+ "nodeType": "ExpressionStatement",
+ "src": "14796:75:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 723,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 689,
+ "src": "14891:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 657,
+ "id": 724,
+ "nodeType": "Return",
+ "src": "14884:13:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 633,
+ "nodeType": "StructuredDocumentation",
+ "src": "12684:1091:0",
+ "text": " @dev converts any other token to BNT in the bancor network by following\na predefined conversion path and transfers the result to an account on a different blockchain\n note that the network should already have been given allowance of the source token (if not ETH)\n @param _path conversion path, see conversion path format above\n @param _amount amount to convert from, in the source token\n @param _minReturn if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero\n @param _targetBlockchain blockchain BNT will be issued on\n @param _targetAccount address/account on the target blockchain to send the BNT to\n @param _conversionId pre-determined unique (if non zero) id which refers to this transaction\n @param _affiliateAccount affiliate account\n @param _affiliateFee affiliate fee in PPM\n @return the amount of BNT received from this conversion"
+ },
+ "functionSelector": "cb32564e",
+ "id": 726,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 653,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 640,
+ "src": "14122:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 654,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 652,
+ "name": "greaterThanZero",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22595,
+ "src": "14106:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$_t_uint256_$",
+ "typeString": "modifier (uint256)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "14106:27:0"
+ }
+ ],
+ "name": "xConvert2",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 651,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 636,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "13810:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 634,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "13810:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 635,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "13810:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 638,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "13843:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 637,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "13843:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 640,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "13869:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 639,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "13869:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 642,
+ "mutability": "mutable",
+ "name": "_targetBlockchain",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "13898:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ "typeName": {
+ "id": 641,
+ "name": "bytes32",
+ "nodeType": "ElementaryTypeName",
+ "src": "13898:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 644,
+ "mutability": "mutable",
+ "name": "_targetAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "13934:22:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ "typeName": {
+ "id": 643,
+ "name": "bytes32",
+ "nodeType": "ElementaryTypeName",
+ "src": "13934:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 646,
+ "mutability": "mutable",
+ "name": "_conversionId",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "13967:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 645,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "13967:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 648,
+ "mutability": "mutable",
+ "name": "_affiliateAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "13999:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 647,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "13999:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 650,
+ "mutability": "mutable",
+ "name": "_affiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "14035:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 649,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "14035:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "13799:264:0"
+ },
+ "returnParameters": {
+ "id": 657,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 656,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "14152:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 655,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "14152:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "14151:9:0"
+ },
+ "scope": 1976,
+ "src": "13781:1124:0",
+ "stateMutability": "payable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 777,
+ "nodeType": "Block",
+ "src": "16040:423:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "id": 752,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 745,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 730,
+ "src": "16133:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 747,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 746,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16139:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "16133:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 744,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "16121:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 748,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "16121:21:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "id": 749,
+ "name": "_bancorX",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 732,
+ "src": "16146:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ }
+ },
+ "id": 750,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "token",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 3530,
+ "src": "16146:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "function () view external returns (contract IERC20Token)"
+ }
+ },
+ "id": 751,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "16146:16:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "16121:41:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f534f555243455f544f4b454e",
+ "id": 753,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16164:26:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_0f690a2bdb8b25e0198ca38056ef0e9f045e379ec977ffdcb1486f3c53b6e8fa",
+ "typeString": "literal_string \"ERR_INVALID_SOURCE_TOKEN\""
+ },
+ "value": "ERR_INVALID_SOURCE_TOKEN"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_0f690a2bdb8b25e0198ca38056ef0e9f045e379ec977ffdcb1486f3c53b6e8fa",
+ "typeString": "literal_string \"ERR_INVALID_SOURCE_TOKEN\""
+ }
+ ],
+ "id": 743,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "16113:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 754,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "16113:78:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 755,
+ "nodeType": "ExpressionStatement",
+ "src": "16113:78:0"
+ },
+ {
+ "assignments": [
+ 757
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 757,
+ "mutability": "mutable",
+ "name": "amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 777,
+ "src": "16260:14:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 756,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "16260:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 764,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 760,
+ "name": "_conversionId",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 734,
+ "src": "16305:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 761,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "16320:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 762,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sender",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "16320:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 758,
+ "name": "_bancorX",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 732,
+ "src": "16277:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ }
+ },
+ "id": 759,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "getXTransferAmount",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 3550,
+ "src": "16277:27:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_uint256_$_t_address_$returns$_t_uint256_$",
+ "typeString": "function (uint256,address) view external returns (uint256)"
+ }
+ },
+ "id": 763,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "16277:54:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "16260:71:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 766,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 730,
+ "src": "16400:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 767,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 757,
+ "src": "16407:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 768,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 736,
+ "src": "16415:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 769,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 738,
+ "src": "16427:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 772,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16449:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 771,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "16441:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 770,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "16441:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 773,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "16441:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 774,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16453:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 765,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "16386:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 775,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "16386:69:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 742,
+ "id": 776,
+ "nodeType": "Return",
+ "src": "16379:76:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 727,
+ "nodeType": "StructuredDocumentation",
+ "src": "14913:937:0",
+ "text": " @dev allows a user to convert a token that was sent from another blockchain into any other\n token on the BancorNetwork\n ideally this transaction is created before the previous conversion is even complete, so\n so the input amount isn't known at that point - the amount is actually take from the\n BancorX contract directly by specifying the conversion id\n @param _path conversion path\n @param _bancorX address of the BancorX contract for the source token\n @param _conversionId pre-determined unique (if non zero) id which refers to this conversion\n @param _minReturn if the conversion results in an amount smaller than the minimum return - it is cancelled, must be nonzero\n @param _beneficiary wallet to receive the conversion result\n @return amount of tokens received from the conversion"
+ },
+ "functionSelector": "89f9cc61",
+ "id": 778,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "completeXConversion",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 739,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 730,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 778,
+ "src": "15885:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 728,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "15885:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 729,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "15885:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 732,
+ "mutability": "mutable",
+ "name": "_bancorX",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 778,
+ "src": "15909:17:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 731,
+ "name": "IBancorX",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 3551,
+ "src": "15909:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 734,
+ "mutability": "mutable",
+ "name": "_conversionId",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 778,
+ "src": "15928:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 733,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "15928:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 736,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 778,
+ "src": "15951:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 735,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "15951:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 738,
+ "mutability": "mutable",
+ "name": "_beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 778,
+ "src": "15971:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 737,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "15971:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "15884:116:0"
+ },
+ "returnParameters": {
+ "id": 742,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 741,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 778,
+ "src": "16026:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 740,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "16026:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "16025:9:0"
+ },
+ "scope": 1976,
+ "src": "15856:607:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 997,
+ "nodeType": "Block",
+ "src": "17298:2483:0",
+ "statements": [
+ {
+ "assignments": [
+ 796
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 796,
+ "mutability": "mutable",
+ "name": "toAmount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 997,
+ "src": "17309:16:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 795,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "17309:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 797,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "17309:16:0"
+ },
+ {
+ "assignments": [
+ 799
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 799,
+ "mutability": "mutable",
+ "name": "fromAmount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 997,
+ "src": "17336:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 798,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "17336:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 801,
+ "initialValue": {
+ "argumentTypes": null,
+ "id": 800,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 784,
+ "src": "17357:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "17336:28:0"
+ },
+ {
+ "body": {
+ "id": 986,
+ "nodeType": "Block",
+ "src": "17465:2151:0",
+ "statements": [
+ {
+ "assignments": [
+ 814
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 814,
+ "mutability": "mutable",
+ "name": "stepData",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 986,
+ "src": "17480:30:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 813,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "17480:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 818,
+ "initialValue": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 815,
+ "name": "_data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 782,
+ "src": "17513:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 817,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 816,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 803,
+ "src": "17519:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "17513:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "17480:41:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 819,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "17574:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 820,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "isV28OrHigherConverter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 56,
+ "src": "17574:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "id": 864,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 855,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18191:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 856,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "18191:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 860,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18235:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 861,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "anchor",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 48,
+ "src": "18235:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ ],
+ "id": 859,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "18227:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 858,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "18227:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 862,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18227:24:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 857,
+ "name": "ISmartToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21182,
+ "src": "18215:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_ISmartToken_$21182_$",
+ "typeString": "type(contract ISmartToken)"
+ }
+ },
+ "id": 863,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18215:37:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_ISmartToken_$21182",
+ "typeString": "contract ISmartToken"
+ }
+ },
+ "src": "18191:61:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 877,
+ "nodeType": "IfStatement",
+ "src": "18187:272:0",
+ "trueBody": {
+ "id": 876,
+ "nodeType": "Block",
+ "src": "18254:205:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 866,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18381:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 867,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "18381:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 870,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18411:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 871,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "converter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 46,
+ "src": "18411:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 869,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "18403:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 868,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "18403:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 872,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18403:27:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 873,
+ "name": "fromAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 799,
+ "src": "18432:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 865,
+ "name": "ensureAllowance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1511,
+ "src": "18365:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,uint256)"
+ }
+ },
+ "id": 874,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18365:78:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 875,
+ "nodeType": "ExpressionStatement",
+ "src": "18365:78:0"
+ }
+ ]
+ }
+ },
+ "id": 878,
+ "nodeType": "IfStatement",
+ "src": "17570:889:0",
+ "trueBody": {
+ "id": 854,
+ "nodeType": "Block",
+ "src": "17607:416:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 841,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 835,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 823,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 821,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 803,
+ "src": "17820:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 822,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17825:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "17820:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "id": 834,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 824,
+ "name": "_data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 782,
+ "src": "17830:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 828,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 827,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 825,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 803,
+ "src": "17836:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 826,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17840:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "17836:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "17830:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 829,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "17830:24:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 832,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "17866:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 831,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "17858:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 830,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "17858:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 833,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "17858:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "src": "17830:41:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "17820:51:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 840,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "!",
+ "prefix": true,
+ "src": "17875:34:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 836,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "17876:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 839,
+ "indexExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 837,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "17888:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 838,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "17888:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "17876:33:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "17820:89:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 853,
+ "nodeType": "IfStatement",
+ "src": "17816:191:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 843,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "17945:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 844,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "17945:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 847,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "17975:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 848,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "converter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 46,
+ "src": "17975:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 846,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "17967:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 845,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "17967:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 849,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "17967:27:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 850,
+ "name": "fromAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 799,
+ "src": "17996:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 842,
+ "name": "safeTransfer",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22475,
+ "src": "17932:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,uint256)"
+ }
+ },
+ "id": 851,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "17932:75:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 852,
+ "nodeType": "ExpressionStatement",
+ "src": "17932:75:0"
+ }
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "id": 881,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "!",
+ "prefix": true,
+ "src": "18513:32:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 879,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18514:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 880,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "isV28OrHigherConverter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 56,
+ "src": "18514:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "condition": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 900,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "18710:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 903,
+ "indexExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 901,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18722:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 902,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "18722:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "18710:33:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 937,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 923,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "18946:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 927,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18984:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 928,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "18984:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 929,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "19006:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 930,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "19006:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 931,
+ "name": "fromAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 799,
+ "src": "19028:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 932,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "19040:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 933,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sender",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "19040:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 934,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "19052:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 935,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "19052:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 924,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18957:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 925,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "converter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 46,
+ "src": "18957:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 926,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "convert",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13228,
+ "src": "18957:26:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_payable$_t_contract$_IERC20Token_$21127_$_t_contract$_IERC20Token_$21127_$_t_uint256_$_t_address_$_t_address_payable_$returns$_t_uint256_$",
+ "typeString": "function (contract IERC20Token,contract IERC20Token,uint256,address,address payable) payable external returns (uint256)"
+ }
+ },
+ "id": 936,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18957:116:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "18946:127:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 938,
+ "nodeType": "ExpressionStatement",
+ "src": "18946:127:0"
+ },
+ "id": 939,
+ "nodeType": "IfStatement",
+ "src": "18706:367:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 921,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 904,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "18762:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 911,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18820:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 912,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "18820:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 913,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18842:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 914,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "18842:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 915,
+ "name": "fromAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 799,
+ "src": "18864:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 916,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "18876:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 917,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sender",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "18876:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 918,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18888:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 919,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "18888:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 905,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18773:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 906,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "converter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 46,
+ "src": "18773:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 907,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "convert",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13228,
+ "src": "18773:26:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_payable$_t_contract$_IERC20Token_$21127_$_t_contract$_IERC20Token_$21127_$_t_uint256_$_t_address_$_t_address_payable_$returns$_t_uint256_$",
+ "typeString": "function (contract IERC20Token,contract IERC20Token,uint256,address,address payable) payable external returns (uint256)"
+ }
+ },
+ "id": 910,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "names": [
+ "value"
+ ],
+ "nodeType": "FunctionCallOptions",
+ "options": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 908,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "18808:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 909,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "value",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "18808:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "src": "18773:46:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_payable$_t_contract$_IERC20Token_$21127_$_t_contract$_IERC20Token_$21127_$_t_uint256_$_t_address_$_t_address_payable_$returns$_t_uint256_$value",
+ "typeString": "function (contract IERC20Token,contract IERC20Token,uint256,address,address payable) payable external returns (uint256)"
+ }
+ },
+ "id": 920,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18773:136:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "18762:147:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 922,
+ "nodeType": "ExpressionStatement",
+ "src": "18762:147:0"
+ }
+ },
+ "id": 940,
+ "nodeType": "IfStatement",
+ "src": "18509:564:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 898,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 882,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "18564:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 891,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18628:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 892,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "18628:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 893,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18650:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 894,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "18650:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 895,
+ "name": "fromAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 799,
+ "src": "18672:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 896,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18684:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 886,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18600:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 887,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "converter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 46,
+ "src": "18600:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 885,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "18592:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 884,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "18592:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 888,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18592:27:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "id": 883,
+ "name": "ILegacyConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 26,
+ "src": "18575:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_ILegacyConverter_$26_$",
+ "typeString": "type(contract ILegacyConverter)"
+ }
+ },
+ "id": 889,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18575:45:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_ILegacyConverter_$26",
+ "typeString": "contract ILegacyConverter"
+ }
+ },
+ "id": 890,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "change",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 25,
+ "src": "18575:52:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_nonpayable$_t_contract$_IERC20Token_$21127_$_t_contract$_IERC20Token_$21127_$_t_uint256_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (contract IERC20Token,contract IERC20Token,uint256,uint256) external returns (uint256)"
+ }
+ },
+ "id": 897,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18575:111:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "18564:122:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 899,
+ "nodeType": "ExpressionStatement",
+ "src": "18564:122:0"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 941,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "19138:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 942,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "processAffiliateFee",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 58,
+ "src": "19138:28:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 968,
+ "nodeType": "IfStatement",
+ "src": "19134:308:0",
+ "trueBody": {
+ "id": 967,
+ "nodeType": "Block",
+ "src": "19168:274:0",
+ "statements": [
+ {
+ "assignments": [
+ 944
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 944,
+ "mutability": "mutable",
+ "name": "affiliateAmount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 967,
+ "src": "19187:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 943,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "19187:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 952,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 950,
+ "name": "PPM_RESOLUTION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 39,
+ "src": "19245:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 947,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 790,
+ "src": "19226:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 945,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "19213:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 946,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "19213:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 948,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "19213:27:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 949,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "div",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22353,
+ "src": "19213:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 951,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "19213:47:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "19187:73:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 957,
+ "name": "_affiliateAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 788,
+ "src": "19317:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 958,
+ "name": "affiliateAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 944,
+ "src": "19336:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 954,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "19287:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 955,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "19287:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "id": 956,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "transfer",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 21106,
+ "src": "19287:29:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
+ "typeString": "function (address,uint256) external returns (bool)"
+ }
+ },
+ "id": 959,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "19287:65:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f4645455f5452414e534645525f4641494c4544",
+ "id": 960,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "19354:25:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_adc6d664872bc68defa0e975019744f9c0f552331af13f5f130791cee181d10c",
+ "typeString": "literal_string \"ERR_FEE_TRANSFER_FAILED\""
+ },
+ "value": "ERR_FEE_TRANSFER_FAILED"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_adc6d664872bc68defa0e975019744f9c0f552331af13f5f130791cee181d10c",
+ "typeString": "literal_string \"ERR_FEE_TRANSFER_FAILED\""
+ }
+ ],
+ "id": 953,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "19279:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 961,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "19279:101:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 962,
+ "nodeType": "ExpressionStatement",
+ "src": "19279:101:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 965,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 963,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "19399:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 964,
+ "name": "affiliateAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 944,
+ "src": "19411:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "19399:27:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 966,
+ "nodeType": "ExpressionStatement",
+ "src": "19399:27:0"
+ }
+ ]
+ }
+ },
+ {
+ "eventCall": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 970,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "19474:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 971,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "anchor",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 48,
+ "src": "19474:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 972,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "19491:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 973,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "19491:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 974,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "19513:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 975,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "19513:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 976,
+ "name": "fromAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 799,
+ "src": "19535:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 977,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "19547:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 978,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "19557:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 979,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sender",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "19557:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "id": 969,
+ "name": "Conversion",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 81,
+ "src": "19463:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_event_nonpayable$_t_contract$_IConverterAnchor_$13349_$_t_contract$_IERC20Token_$21127_$_t_contract$_IERC20Token_$21127_$_t_uint256_$_t_uint256_$_t_address_$returns$__$",
+ "typeString": "function (contract IConverterAnchor,contract IERC20Token,contract IERC20Token,uint256,uint256,address)"
+ }
+ },
+ "id": 980,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "19463:105:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 981,
+ "nodeType": "EmitStatement",
+ "src": "19458:110:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 984,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 982,
+ "name": "fromAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 799,
+ "src": "19583:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 983,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "19596:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "19583:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 985,
+ "nodeType": "ExpressionStatement",
+ "src": "19583:21:0"
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 809,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 806,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 803,
+ "src": "17442:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 807,
+ "name": "_data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 782,
+ "src": "17446:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 808,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "17446:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "17442:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 987,
+ "initializationExpression": {
+ "assignments": [
+ 803
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 803,
+ "mutability": "mutable",
+ "name": "i",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 987,
+ "src": "17427:9:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 802,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "17427:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 805,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 804,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17439:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "17427:13:0"
+ },
+ "loopExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 811,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "++",
+ "prefix": false,
+ "src": "17460:3:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "id": 810,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 803,
+ "src": "17460:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 812,
+ "nodeType": "ExpressionStatement",
+ "src": "17460:3:0"
+ },
+ "nodeType": "ForStatement",
+ "src": "17422:2194:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 991,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 989,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "19700:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 990,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 786,
+ "src": "19712:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "19700:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f52455455524e5f544f4f5f4c4f57",
+ "id": 992,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "19724:20:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_c3237cc40443cfd1e0e9492ef35b7447eab6349fb6eac5eb1ec626edd3c555aa",
+ "typeString": "literal_string \"ERR_RETURN_TOO_LOW\""
+ },
+ "value": "ERR_RETURN_TOO_LOW"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_c3237cc40443cfd1e0e9492ef35b7447eab6349fb6eac5eb1ec626edd3c555aa",
+ "typeString": "literal_string \"ERR_RETURN_TOO_LOW\""
+ }
+ ],
+ "id": 988,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "19692:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 993,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "19692:53:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 994,
+ "nodeType": "ExpressionStatement",
+ "src": "19692:53:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 995,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "19765:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 794,
+ "id": 996,
+ "nodeType": "Return",
+ "src": "19758:15:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 779,
+ "nodeType": "StructuredDocumentation",
+ "src": "16471:603:0",
+ "text": " @dev executes the actual conversion by following the conversion path\n @param _data conversion data, see ConversionStep struct above\n @param _amount amount to convert from, in the source token\n @param _minReturn if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero\n @param _affiliateAccount affiliate account\n @param _affiliateFee affiliate fee in PPM\n @return amount of tokens received from the conversion"
+ },
+ "id": 998,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "doConversion",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 791,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 782,
+ "mutability": "mutable",
+ "name": "_data",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 998,
+ "src": "17112:29:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ },
+ "typeName": {
+ "baseType": {
+ "contractScope": null,
+ "id": 780,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "17112:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "id": 781,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "17112:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_storage_$dyn_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 784,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 998,
+ "src": "17152:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 783,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "17152:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 786,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 998,
+ "src": "17178:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 785,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "17178:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 788,
+ "mutability": "mutable",
+ "name": "_affiliateAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 998,
+ "src": "17207:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 787,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "17207:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 790,
+ "mutability": "mutable",
+ "name": "_affiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 998,
+ "src": "17243:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 789,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "17243:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "17101:170:0"
+ },
+ "returnParameters": {
+ "id": 794,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 793,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 998,
+ "src": "17289:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 792,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "17289:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "17288:9:0"
+ },
+ "scope": 1976,
+ "src": "17080:2701:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 1109,
+ "nodeType": "Block",
+ "src": "20232:1606:0",
+ "statements": [
+ {
+ "assignments": [
+ 1009
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1009,
+ "mutability": "mutable",
+ "name": "firstConverter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1109,
+ "src": "20243:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1008,
+ "name": "IConverter",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13340,
+ "src": "20243:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1018,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1013,
+ "name": "_anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1003,
+ "src": "20290:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ "id": 1014,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "owner",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22838,
+ "src": "20290:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_address_$",
+ "typeString": "function () view external returns (address)"
+ }
+ },
+ "id": 1015,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20290:15:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1012,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "20282:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_payable_$",
+ "typeString": "type(address payable)"
+ },
+ "typeName": {
+ "id": 1011,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "20282:8:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1016,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20282:24:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "id": 1010,
+ "name": "IConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 13340,
+ "src": "20271:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IConverter_$13340_$",
+ "typeString": "type(contract IConverter)"
+ }
+ },
+ "id": 1017,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20271:36:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "20243:64:0"
+ },
+ {
+ "assignments": [
+ 1020
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1020,
+ "mutability": "mutable",
+ "name": "isNewerConverter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1109,
+ "src": "20318:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 1019,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "20318:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1024,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1022,
+ "name": "firstConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1009,
+ "src": "20365:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1021,
+ "name": "isV28OrHigherConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1719,
+ "src": "20342:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$returns$_t_bool_$",
+ "typeString": "function (contract IConverter) view returns (bool)"
+ }
+ },
+ "id": 1023,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20342:38:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "20318:62:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1028,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1025,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "20413:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 1026,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "value",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "20413:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1027,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20425:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "20413:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "condition": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1055,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "20955:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 1057,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 1056,
+ "name": "_sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1001,
+ "src": "20967:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "20955:25:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "id": 1106,
+ "nodeType": "Block",
+ "src": "21447:384:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "id": 1082,
+ "name": "isNewerConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1020,
+ "src": "21605:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1095,
+ "name": "_sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1001,
+ "src": "21770:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1096,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "21784:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 1097,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sender",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "21784:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1100,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "21804:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 1099,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "21796:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1098,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "21796:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1101,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21796:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1102,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1005,
+ "src": "21811:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1094,
+ "name": "safeTransferFrom",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22525,
+ "src": "21753:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,address,uint256)"
+ }
+ },
+ "id": 1103,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21753:66:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1104,
+ "nodeType": "ExpressionStatement",
+ "src": "21753:66:0"
+ },
+ "id": 1105,
+ "nodeType": "IfStatement",
+ "src": "21601:218:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1084,
+ "name": "_sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1001,
+ "src": "21657:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1085,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "21671:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 1086,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sender",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "21671:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1089,
+ "name": "firstConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1009,
+ "src": "21691:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1088,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "21683:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1087,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "21683:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1090,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21683:23:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1091,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1005,
+ "src": "21708:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1083,
+ "name": "safeTransferFrom",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22525,
+ "src": "21640:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,address,uint256)"
+ }
+ },
+ "id": 1092,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21640:76:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1093,
+ "nodeType": "ExpressionStatement",
+ "src": "21640:76:0"
+ }
+ }
+ ]
+ },
+ "id": 1107,
+ "nodeType": "IfStatement",
+ "src": "20951:880:0",
+ "trueBody": {
+ "id": 1081,
+ "nodeType": "Block",
+ "src": "20982:420:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1059,
+ "name": "_sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1001,
+ "src": "21184:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1060,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "21198:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 1061,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sender",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "21198:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1064,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "21218:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 1063,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "21210:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1062,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "21210:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1065,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21210:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1066,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1005,
+ "src": "21225:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1058,
+ "name": "safeTransferFrom",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22525,
+ "src": "21167:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,address,uint256)"
+ }
+ },
+ "id": 1067,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21167:66:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1068,
+ "nodeType": "ExpressionStatement",
+ "src": "21167:66:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "id": 1069,
+ "name": "isNewerConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1020,
+ "src": "21303:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1080,
+ "nodeType": "IfStatement",
+ "src": "21299:91:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1077,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1005,
+ "src": "21382:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1073,
+ "name": "_sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1001,
+ "src": "21358:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "id": 1072,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "21350:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1071,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "21350:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1074,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21350:21:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1070,
+ "name": "IEtherToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21153,
+ "src": "21338:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IEtherToken_$21153_$",
+ "typeString": "type(contract IEtherToken)"
+ }
+ },
+ "id": 1075,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21338:34:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ },
+ "id": 1076,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "withdraw",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 21140,
+ "src": "21338:43:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$returns$__$",
+ "typeString": "function (uint256) external"
+ }
+ },
+ "id": 1078,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21338:52:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1079,
+ "nodeType": "ExpressionStatement",
+ "src": "21338:52:0"
+ }
+ }
+ ]
+ }
+ },
+ "id": 1108,
+ "nodeType": "IfStatement",
+ "src": "20409:1422:0",
+ "trueBody": {
+ "id": 1054,
+ "nodeType": "Block",
+ "src": "20428:485:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1033,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1030,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "20486:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 1031,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "value",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "20486:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 1032,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1005,
+ "src": "20499:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "20486:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f4554485f414d4f554e545f4d49534d41544348",
+ "id": 1034,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20508:25:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_b27c160ac497b67c4fef6b5554e0b1a41f3c9b44e4bd8482662df760b76c093b",
+ "typeString": "literal_string \"ERR_ETH_AMOUNT_MISMATCH\""
+ },
+ "value": "ERR_ETH_AMOUNT_MISMATCH"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_b27c160ac497b67c4fef6b5554e0b1a41f3c9b44e4bd8482662df760b76c093b",
+ "typeString": "literal_string \"ERR_ETH_AMOUNT_MISMATCH\""
+ }
+ ],
+ "id": 1029,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "20478:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 1035,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20478:56:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1036,
+ "nodeType": "ExpressionStatement",
+ "src": "20478:56:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "id": 1038,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "!",
+ "prefix": true,
+ "src": "20768:17:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "id": 1037,
+ "name": "isNewerConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1020,
+ "src": "20769:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1053,
+ "nodeType": "IfStatement",
+ "src": "20764:137:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1043,
+ "name": "firstConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1009,
+ "src": "20854:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1042,
+ "name": "getConverterEtherTokenAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1552,
+ "src": "20824:29:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$returns$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "function (contract IConverter) view returns (contract IERC20Token)"
+ }
+ },
+ "id": 1044,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20824:45:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "id": 1041,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "20816:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1040,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "20816:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1045,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20816:54:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1039,
+ "name": "IEtherToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21153,
+ "src": "20804:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IEtherToken_$21153_$",
+ "typeString": "type(contract IEtherToken)"
+ }
+ },
+ "id": 1046,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20804:67:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ },
+ "id": 1047,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "deposit",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 21135,
+ "src": "20804:75:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_payable$__$returns$__$",
+ "typeString": "function () payable external"
+ }
+ },
+ "id": 1050,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "names": [
+ "value"
+ ],
+ "nodeType": "FunctionCallOptions",
+ "options": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1048,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "20888:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 1049,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "value",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "20888:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "src": "20804:95:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_payable$__$returns$__$value",
+ "typeString": "function () payable external"
+ }
+ },
+ "id": 1051,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20804:97:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1052,
+ "nodeType": "ExpressionStatement",
+ "src": "20804:97:0"
+ }
+ }
+ ]
+ }
+ }
+ ]
+ },
+ "documentation": {
+ "id": 999,
+ "nodeType": "StructuredDocumentation",
+ "src": "19789:333:0",
+ "text": " @dev validates msg.value and prepares the conversion source token for the conversion\n @param _sourceToken source token of the first conversion step\n @param _anchor converter anchor of the first conversion step\n @param _amount amount to convert from, in the source token"
+ },
+ "id": 1110,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "handleSourceToken",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1006,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1001,
+ "mutability": "mutable",
+ "name": "_sourceToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1110,
+ "src": "20155:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1000,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "20155:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1003,
+ "mutability": "mutable",
+ "name": "_anchor",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1110,
+ "src": "20181:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1002,
+ "name": "IConverterAnchor",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13349,
+ "src": "20181:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1005,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1110,
+ "src": "20207:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1004,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "20207:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "20154:69:0"
+ },
+ "returnParameters": {
+ "id": 1007,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "20232:0:0"
+ },
+ "scope": 1976,
+ "src": "20128:1710:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 1173,
+ "nodeType": "Block",
+ "src": "22295:780:0",
+ "statements": [
+ {
+ "assignments": [
+ 1122
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1122,
+ "mutability": "mutable",
+ "name": "stepData",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1173,
+ "src": "22306:30:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1121,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "22306:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1129,
+ "initialValue": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1123,
+ "name": "_data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1114,
+ "src": "22339:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1128,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1127,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1124,
+ "name": "_data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1114,
+ "src": "22345:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1125,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "22345:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 1126,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "22360:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "22345:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "22339:23:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "22306:56:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "id": 1136,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1130,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1122,
+ "src": "22444:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1131,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "22444:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1134,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "22476:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 1133,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "22468:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1132,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "22468:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1135,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "22468:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "src": "22444:37:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1138,
+ "nodeType": "IfStatement",
+ "src": "22440:63:0",
+ "trueBody": {
+ "expression": null,
+ "functionReturnParameters": 1120,
+ "id": 1137,
+ "nodeType": "Return",
+ "src": "22496:7:0"
+ }
+ },
+ {
+ "assignments": [
+ 1140
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1140,
+ "mutability": "mutable",
+ "name": "targetToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1173,
+ "src": "22515:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1139,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "22515:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1143,
+ "initialValue": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1141,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1122,
+ "src": "22541:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1142,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "22541:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "22515:46:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1144,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "22607:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 1146,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 1145,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1140,
+ "src": "22619:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "22607:24:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "id": 1171,
+ "nodeType": "Block",
+ "src": "22993:75:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1166,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1140,
+ "src": "23021:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1167,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1118,
+ "src": "23034:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1168,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1116,
+ "src": "23048:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1165,
+ "name": "safeTransfer",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22475,
+ "src": "23008:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,uint256)"
+ }
+ },
+ "id": 1169,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "23008:48:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1170,
+ "nodeType": "ExpressionStatement",
+ "src": "23008:48:0"
+ }
+ ]
+ },
+ "id": 1172,
+ "nodeType": "IfStatement",
+ "src": "22603:465:0",
+ "trueBody": {
+ "id": 1164,
+ "nodeType": "Block",
+ "src": "22633:315:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1150,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "!",
+ "prefix": true,
+ "src": "22731:32:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1148,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1122,
+ "src": "22732:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1149,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "isV28OrHigherConverter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 56,
+ "src": "22732:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ ],
+ "id": 1147,
+ "name": "assert",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -3,
+ "src": "22724:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_assert_pure$_t_bool_$returns$__$",
+ "typeString": "function (bool) pure"
+ }
+ },
+ "id": 1151,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "22724:40:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1152,
+ "nodeType": "ExpressionStatement",
+ "src": "22724:40:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1160,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1118,
+ "src": "22914:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1161,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1116,
+ "src": "22928:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1156,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1140,
+ "src": "22889:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "id": 1155,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "22881:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1154,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "22881:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1157,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "22881:20:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1153,
+ "name": "IEtherToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21153,
+ "src": "22869:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IEtherToken_$21153_$",
+ "typeString": "type(contract IEtherToken)"
+ }
+ },
+ "id": 1158,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "22869:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ },
+ "id": 1159,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "withdrawTo",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 21152,
+ "src": "22869:44:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_nonpayable$_t_address_payable_$_t_uint256_$returns$__$",
+ "typeString": "function (address payable,uint256) external"
+ }
+ },
+ "id": 1162,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "22869:67:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1163,
+ "nodeType": "ExpressionStatement",
+ "src": "22869:67:0"
+ }
+ ]
+ }
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1111,
+ "nodeType": "StructuredDocumentation",
+ "src": "21846:330:0",
+ "text": " @dev handles the conversion target token if the network still holds it at the end of the conversion\n @param _data conversion data, see ConversionStep struct above\n @param _amount conversion target amount\n @param _beneficiary wallet to receive the conversion result"
+ },
+ "id": 1174,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "handleTargetToken",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1119,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1114,
+ "mutability": "mutable",
+ "name": "_data",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1174,
+ "src": "22209:29:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ },
+ "typeName": {
+ "baseType": {
+ "contractScope": null,
+ "id": 1112,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "22209:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "id": 1113,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "22209:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_storage_$dyn_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1116,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1174,
+ "src": "22240:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1115,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "22240:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1118,
+ "mutability": "mutable",
+ "name": "_beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1174,
+ "src": "22257:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 1117,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "22257:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "22208:78:0"
+ },
+ "returnParameters": {
+ "id": 1120,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "22295:0:0"
+ },
+ "scope": 1976,
+ "src": "22182:893:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 1467,
+ "nodeType": "Block",
+ "src": "23760:4093:0",
+ "statements": [
+ {
+ "assignments": [
+ 1191
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1191,
+ "mutability": "mutable",
+ "name": "data",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1467,
+ "src": "23771:28:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ },
+ "typeName": {
+ "baseType": {
+ "contractScope": null,
+ "id": 1189,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "23771:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "id": 1190,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "23771:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_storage_$dyn_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1200,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1198,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1195,
+ "name": "_conversionPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1178,
+ "src": "23823:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 1196,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "23823:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 1197,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "23848:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "23823:26:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1194,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "NewExpression",
+ "src": "23802:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_objectcreation_pure$_t_uint256_$returns$_t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr_$",
+ "typeString": "function (uint256) pure returns (struct BancorNetwork.ConversionStep memory[] memory)"
+ },
+ "typeName": {
+ "baseType": {
+ "contractScope": null,
+ "id": 1192,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "23806:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "id": 1193,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "23806:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_storage_$dyn_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ }
+ }
+ },
+ "id": 1199,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "23802:48:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "23771:79:0"
+ },
+ {
+ "assignments": [
+ 1202
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1202,
+ "mutability": "mutable",
+ "name": "affiliateFeeProcessed",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1467,
+ "src": "23863:26:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 1201,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "23863:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1204,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "66616c7365",
+ "id": 1203,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "23892:5:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "false"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "23863:34:0"
+ },
+ {
+ "assignments": [
+ 1206
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1206,
+ "mutability": "mutable",
+ "name": "bntToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1467,
+ "src": "23908:20:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1205,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "23908:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1212,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1209,
+ "name": "BNT_TOKEN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21551,
+ "src": "23953:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ ],
+ "id": 1208,
+ "name": "addressOf",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21718,
+ "src": "23943:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$",
+ "typeString": "function (bytes32) view returns (address)"
+ }
+ },
+ "id": 1210,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "23943:20:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1207,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "23931:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 1211,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "23931:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "23908:56:0"
+ },
+ {
+ "assignments": [
+ 1214
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1214,
+ "mutability": "mutable",
+ "name": "i",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1467,
+ "src": "24060:9:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1213,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "24060:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1215,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24060:9:0"
+ },
+ {
+ "body": {
+ "id": 1303,
+ "nodeType": "Block",
+ "src": "24132:1199:0",
+ "statements": [
+ {
+ "assignments": [
+ 1231
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1231,
+ "mutability": "mutable",
+ "name": "anchor",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1303,
+ "src": "24147:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1230,
+ "name": "IConverterAnchor",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13349,
+ "src": "24147:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1239,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1233,
+ "name": "_conversionPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1178,
+ "src": "24190:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 1237,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1236,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1234,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "24206:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 1235,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24210:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "24206:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "24190:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1232,
+ "name": "IConverterAnchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 13349,
+ "src": "24173:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IConverterAnchor_$13349_$",
+ "typeString": "type(contract IConverterAnchor)"
+ }
+ },
+ "id": 1238,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24173:40:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24147:66:0"
+ },
+ {
+ "assignments": [
+ 1241
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1241,
+ "mutability": "mutable",
+ "name": "converter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1303,
+ "src": "24228:20:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1240,
+ "name": "IConverter",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13340,
+ "src": "24228:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1250,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1245,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1231,
+ "src": "24270:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ "id": 1246,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "owner",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22838,
+ "src": "24270:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_address_$",
+ "typeString": "function () view external returns (address)"
+ }
+ },
+ "id": 1247,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24270:14:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1244,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "24262:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_payable_$",
+ "typeString": "type(address payable)"
+ },
+ "typeName": {
+ "id": 1243,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "24262:8:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1248,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24262:23:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "id": 1242,
+ "name": "IConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 13340,
+ "src": "24251:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IConverter_$13340_$",
+ "typeString": "type(contract IConverter)"
+ }
+ },
+ "id": 1249,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24251:35:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24228:58:0"
+ },
+ {
+ "assignments": [
+ 1252
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1252,
+ "mutability": "mutable",
+ "name": "targetToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1303,
+ "src": "24301:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1251,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "24301:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1260,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1254,
+ "name": "_conversionPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1178,
+ "src": "24339:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 1258,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1257,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1255,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "24355:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 1256,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24359:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "24355:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "24339:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1253,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "24327:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 1259,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24327:35:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24301:61:0"
+ },
+ {
+ "assignments": [
+ 1262
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1262,
+ "mutability": "mutable",
+ "name": "processAffiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1303,
+ "src": "24455:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 1261,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "24455:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1271,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 1270,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 1266,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1263,
+ "name": "_affiliateFeeEnabled",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1182,
+ "src": "24482:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 1265,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "!",
+ "prefix": true,
+ "src": "24506:22:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "id": 1264,
+ "name": "affiliateFeeProcessed",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1202,
+ "src": "24507:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "24482:46:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "id": 1269,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1267,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1252,
+ "src": "24532:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 1268,
+ "name": "bntToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1206,
+ "src": "24547:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "24532:23:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "24482:73:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24455:100:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "id": 1272,
+ "name": "processAffiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1262,
+ "src": "24574:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1277,
+ "nodeType": "IfStatement",
+ "src": "24570:70:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1275,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 1273,
+ "name": "affiliateFeeProcessed",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1202,
+ "src": "24612:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "74727565",
+ "id": 1274,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24636:4:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "true"
+ },
+ "src": "24612:28:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 1276,
+ "nodeType": "ExpressionStatement",
+ "src": "24612:28:0"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1301,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1278,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "24657:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1282,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1281,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1279,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "24662:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 1280,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24666:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "24662:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "24657:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1284,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1231,
+ "src": "24758:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1285,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1241,
+ "src": "24834:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1287,
+ "name": "_conversionPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1178,
+ "src": "24938:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 1289,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 1288,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "24954:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "24938:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1286,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "24926:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 1290,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24926:31:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1291,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1252,
+ "src": "24989:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1294,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "25134:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1293,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "25126:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1292,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "25126:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1295,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "25126:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1297,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1241,
+ "src": "25234:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1296,
+ "name": "isV28OrHigherConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1719,
+ "src": "25211:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$returns$_t_bool_$",
+ "typeString": "function (contract IConverter) view returns (bool)"
+ }
+ },
+ "id": 1298,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "25211:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1299,
+ "name": "processAffiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1262,
+ "src": "25284:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ },
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ ],
+ "id": 1283,
+ "name": "ConversionStep",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 59,
+ "src": "24671:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_struct$_ConversionStep_$59_storage_ptr_$",
+ "typeString": "type(struct BancorNetwork.ConversionStep storage pointer)"
+ }
+ },
+ "id": 1300,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "structConstructorCall",
+ "lValueRequested": false,
+ "names": [
+ "anchor",
+ "converter",
+ "sourceToken",
+ "targetToken",
+ "beneficiary",
+ "isV28OrHigherConverter",
+ "processAffiliateFee"
+ ],
+ "nodeType": "FunctionCall",
+ "src": "24671:648:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "src": "24657:662:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1302,
+ "nodeType": "ExpressionStatement",
+ "src": "24657:662:0"
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1225,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1220,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "24092:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1224,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1221,
+ "name": "_conversionPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1178,
+ "src": "24096:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 1222,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "24096:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 1223,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24121:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "24096:26:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "24092:30:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 1304,
+ "initializationExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1218,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 1216,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "24085:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1217,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24089:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "24085:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 1219,
+ "nodeType": "ExpressionStatement",
+ "src": "24085:5:0"
+ },
+ "loopExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1228,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 1226,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "24124:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 1227,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24129:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "24124:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 1229,
+ "nodeType": "ExpressionStatement",
+ "src": "24124:6:0"
+ },
+ "nodeType": "ForStatement",
+ "src": "24080:1251:0"
+ },
+ {
+ "assignments": [
+ 1306
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1306,
+ "mutability": "mutable",
+ "name": "stepData",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1467,
+ "src": "25393:30:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1305,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "25393:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1310,
+ "initialValue": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1307,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "25426:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1309,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1308,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "25431:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "25426:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "25393:40:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1311,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "25448:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 1314,
+ "indexExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1312,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "25460:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1313,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "25460:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "25448:33:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1334,
+ "nodeType": "IfStatement",
+ "src": "25444:472:0",
+ "trueBody": {
+ "id": 1333,
+ "nodeType": "Block",
+ "src": "25483:433:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1315,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "25594:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1316,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "isV28OrHigherConverter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 56,
+ "src": "25594:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1330,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1323,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "25832:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1325,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "25832:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1327,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "25885:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1328,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "converter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 46,
+ "src": "25885:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1326,
+ "name": "getConverterEtherTokenAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1552,
+ "src": "25855:29:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$returns$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "function (contract IConverter) view returns (contract IERC20Token)"
+ }
+ },
+ "id": 1329,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "25855:49:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "25832:72:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "id": 1331,
+ "nodeType": "ExpressionStatement",
+ "src": "25832:72:0"
+ },
+ "id": 1332,
+ "nodeType": "IfStatement",
+ "src": "25590:314:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1321,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1317,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "25644:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1319,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "25644:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 1320,
+ "name": "ETH_RESERVE_ADDRESS",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 44,
+ "src": "25667:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "25644:42:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "id": 1322,
+ "nodeType": "ExpressionStatement",
+ "src": "25644:42:0"
+ }
+ }
+ ]
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1342,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 1335,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "25954:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1336,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "25965:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1341,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1340,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1337,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "25970:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1338,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "25970:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 1339,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "25984:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "25970:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "25965:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "src": "25954:32:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1343,
+ "nodeType": "ExpressionStatement",
+ "src": "25954:32:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1344,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "26001:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 1347,
+ "indexExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1345,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26013:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1346,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "26013:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "26001:33:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1367,
+ "nodeType": "IfStatement",
+ "src": "25997:472:0",
+ "trueBody": {
+ "id": 1366,
+ "nodeType": "Block",
+ "src": "26036:433:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1348,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26147:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1349,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "isV28OrHigherConverter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 56,
+ "src": "26147:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1363,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1356,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26385:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1358,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "26385:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1360,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26438:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1361,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "converter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 46,
+ "src": "26438:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1359,
+ "name": "getConverterEtherTokenAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1552,
+ "src": "26408:29:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$returns$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "function (contract IConverter) view returns (contract IERC20Token)"
+ }
+ },
+ "id": 1362,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "26408:49:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "26385:72:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "id": 1364,
+ "nodeType": "ExpressionStatement",
+ "src": "26385:72:0"
+ },
+ "id": 1365,
+ "nodeType": "IfStatement",
+ "src": "26143:314:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1354,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1350,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26197:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1352,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "26197:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 1353,
+ "name": "ETH_RESERVE_ADDRESS",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 44,
+ "src": "26220:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "26197:42:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "id": 1355,
+ "nodeType": "ExpressionStatement",
+ "src": "26197:42:0"
+ }
+ }
+ ]
+ }
+ },
+ {
+ "body": {
+ "id": 1463,
+ "nodeType": "Block",
+ "src": "26561:1261:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1383,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 1379,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26576:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1380,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "26587:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1382,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 1381,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "26592:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "26587:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "src": "26576:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1384,
+ "nodeType": "ExpressionStatement",
+ "src": "26576:18:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1385,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26746:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1386,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "isV28OrHigherConverter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 56,
+ "src": "26746:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "id": 1461,
+ "nodeType": "Block",
+ "src": "27642:169:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1459,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1449,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "27750:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1451,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "27750:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1456,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "27789:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 1455,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "27781:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1454,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "27781:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1457,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "27781:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1453,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "27773:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_payable_$",
+ "typeString": "type(address payable)"
+ },
+ "typeName": {
+ "id": 1452,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "27773:8:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1458,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "27773:22:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "src": "27750:45:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "id": 1460,
+ "nodeType": "ExpressionStatement",
+ "src": "27750:45:0"
+ }
+ ]
+ },
+ "id": 1462,
+ "nodeType": "IfStatement",
+ "src": "26742:1069:0",
+ "trueBody": {
+ "id": 1448,
+ "nodeType": "Block",
+ "src": "26779:844:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1387,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26902:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1388,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "processAffiliateFee",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 58,
+ "src": "26902:28:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1406,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1401,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "27106:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1405,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1402,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "27111:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1403,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "27111:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 1404,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27125:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "27111:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "27106:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "condition": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1413,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "27310:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1417,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1416,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1414,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "27315:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 1415,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27319:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "27315:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "27310:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1418,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "isV28OrHigherConverter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 56,
+ "src": "27310:34:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1443,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1433,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "27562:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1435,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "27562:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1440,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "27601:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 1439,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "27593:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1438,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "27593:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1441,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "27593:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1437,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "27585:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_payable_$",
+ "typeString": "type(address payable)"
+ },
+ "typeName": {
+ "id": 1436,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "27585:8:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1442,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "27585:22:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "src": "27562:45:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "id": 1444,
+ "nodeType": "ExpressionStatement",
+ "src": "27562:45:0"
+ },
+ "id": 1445,
+ "nodeType": "IfStatement",
+ "src": "27306:301:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1431,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1419,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "27367:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1421,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "27367:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1424,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "27398:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1428,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1427,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1425,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "27403:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 1426,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27407:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "27403:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "27398:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1429,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "converter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 46,
+ "src": "27398:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1423,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "27390:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1422,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "27390:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1430,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "27390:30:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "src": "27367:53:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "id": 1432,
+ "nodeType": "ExpressionStatement",
+ "src": "27367:53:0"
+ }
+ },
+ "id": 1446,
+ "nodeType": "IfStatement",
+ "src": "27102:505:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1411,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1407,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "27149:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1409,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "27149:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 1410,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1180,
+ "src": "27172:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "src": "27149:35:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "id": 1412,
+ "nodeType": "ExpressionStatement",
+ "src": "27149:35:0"
+ }
+ },
+ "id": 1447,
+ "nodeType": "IfStatement",
+ "src": "26898:709:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1399,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1389,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26953:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1391,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "26953:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1396,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "26992:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 1395,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "26984:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1394,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "26984:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1397,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "26984:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1393,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "26976:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_payable_$",
+ "typeString": "type(address payable)"
+ },
+ "typeName": {
+ "id": 1392,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "26976:8:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1398,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "26976:22:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "src": "26953:45:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "id": 1400,
+ "nodeType": "ExpressionStatement",
+ "src": "26953:45:0"
+ }
+ }
+ ]
+ }
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1375,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1372,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "26539:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1373,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "26543:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1374,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "26543:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "26539:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 1464,
+ "initializationExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1370,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 1368,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "26532:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1369,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26536:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "26532:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 1371,
+ "nodeType": "ExpressionStatement",
+ "src": "26532:5:0"
+ },
+ "loopExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1377,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "++",
+ "prefix": false,
+ "src": "26556:3:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "id": 1376,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "26556:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 1378,
+ "nodeType": "ExpressionStatement",
+ "src": "26556:3:0"
+ },
+ "nodeType": "ForStatement",
+ "src": "26527:1295:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1465,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "27841:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "functionReturnParameters": 1187,
+ "id": 1466,
+ "nodeType": "Return",
+ "src": "27834:11:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1175,
+ "nodeType": "StructuredDocumentation",
+ "src": "23083:503:0",
+ "text": " @dev creates a memory cache of all conversion steps data to minimize logic and external calls during conversions\n @param _conversionPath conversion path, see conversion path format above\n @param _beneficiary wallet to receive the conversion result\n @param _affiliateFeeEnabled true if affiliate fee was requested by the sender, false if not\n @return cached conversion data to be ingested later on by the conversion flow"
+ },
+ "id": 1468,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "createConversionData",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1183,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1178,
+ "mutability": "mutable",
+ "name": "_conversionPath",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1468,
+ "src": "23622:32:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1176,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "23622:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1177,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "23622:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1180,
+ "mutability": "mutable",
+ "name": "_beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1468,
+ "src": "23656:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 1179,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "23656:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1182,
+ "mutability": "mutable",
+ "name": "_affiliateFeeEnabled",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1468,
+ "src": "23686:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 1181,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "23686:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "23621:91:0"
+ },
+ "returnParameters": {
+ "id": 1187,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1186,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1468,
+ "src": "23735:23:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ },
+ "typeName": {
+ "baseType": {
+ "contractScope": null,
+ "id": 1184,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "23735:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "id": 1185,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "23735:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_storage_$dyn_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "23734:25:0"
+ },
+ "scope": 1976,
+ "src": "23592:4261:0",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 1510,
+ "nodeType": "Block",
+ "src": "28406:261:0",
+ "statements": [
+ {
+ "assignments": [
+ 1479
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1479,
+ "mutability": "mutable",
+ "name": "allowance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1510,
+ "src": "28417:17:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1478,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "28417:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1488,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1484,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "28462:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 1483,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "28454:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1482,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "28454:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1485,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28454:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1486,
+ "name": "_spender",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1473,
+ "src": "28469:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1480,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1471,
+ "src": "28437:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "id": 1481,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "allowance",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 21097,
+ "src": "28437:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$",
+ "typeString": "function (address,address) view external returns (uint256)"
+ }
+ },
+ "id": 1487,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28437:41:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "28417:61:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1491,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1489,
+ "name": "allowance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1479,
+ "src": "28493:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 1490,
+ "name": "_value",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1475,
+ "src": "28505:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "28493:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1509,
+ "nodeType": "IfStatement",
+ "src": "28489:171:0",
+ "trueBody": {
+ "id": 1508,
+ "nodeType": "Block",
+ "src": "28513:147:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1494,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1492,
+ "name": "allowance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1479,
+ "src": "28532:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1493,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "28544:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "28532:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1501,
+ "nodeType": "IfStatement",
+ "src": "28528:68:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1496,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1471,
+ "src": "28576:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1497,
+ "name": "_spender",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1473,
+ "src": "28584:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1498,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "28594:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1495,
+ "name": "safeApprove",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22428,
+ "src": "28564:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,uint256)"
+ }
+ },
+ "id": 1499,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28564:32:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1500,
+ "nodeType": "ExpressionStatement",
+ "src": "28564:32:0"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1503,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1471,
+ "src": "28623:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1504,
+ "name": "_spender",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1473,
+ "src": "28631:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1505,
+ "name": "_value",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1475,
+ "src": "28641:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1502,
+ "name": "safeApprove",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22428,
+ "src": "28611:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,uint256)"
+ }
+ },
+ "id": 1506,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28611:37:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1507,
+ "nodeType": "ExpressionStatement",
+ "src": "28611:37:0"
+ }
+ ]
+ }
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1469,
+ "nodeType": "StructuredDocumentation",
+ "src": "27861:452:0",
+ "text": " @dev utility, checks whether allowance for the given spender exists and approves one if it doesn't.\n Note that we use the non standard erc-20 interface in which `approve` has no return value so that\n this function will work for both standard and non standard tokens\n @param _token token to check the allowance in\n @param _spender approved address\n @param _value allowance amount"
+ },
+ "id": 1511,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "ensureAllowance",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1476,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1471,
+ "mutability": "mutable",
+ "name": "_token",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1511,
+ "src": "28344:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1470,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "28344:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1473,
+ "mutability": "mutable",
+ "name": "_spender",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1511,
+ "src": "28364:16:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 1472,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "28364:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1475,
+ "mutability": "mutable",
+ "name": "_value",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1511,
+ "src": "28382:14:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1474,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "28382:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "28343:54:0"
+ },
+ "returnParameters": {
+ "id": 1477,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "28406:0:0"
+ },
+ "scope": 1976,
+ "src": "28319:348:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 1551,
+ "nodeType": "Block",
+ "src": "28848:352:0",
+ "statements": [
+ {
+ "assignments": [
+ 1519
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1519,
+ "mutability": "mutable",
+ "name": "reserveCount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1551,
+ "src": "28859:20:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1518,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "28859:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1523,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1520,
+ "name": "_converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1513,
+ "src": "28882:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 1521,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "connectorTokenCount",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13339,
+ "src": "28882:30:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_uint16_$",
+ "typeString": "function () view external returns (uint16)"
+ }
+ },
+ "id": 1522,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28882:32:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint16",
+ "typeString": "uint16"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "28859:55:0"
+ },
+ {
+ "body": {
+ "id": 1547,
+ "nodeType": "Block",
+ "src": "28968:186:0",
+ "statements": [
+ {
+ "assignments": [
+ 1535
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1535,
+ "mutability": "mutable",
+ "name": "reserveTokenAddress",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1547,
+ "src": "28983:31:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1534,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "28983:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1540,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1538,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1525,
+ "src": "29044:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1536,
+ "name": "_converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1513,
+ "src": "29017:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 1537,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "connectorTokens",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13334,
+ "src": "29017:26:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "function (uint256) view external returns (contract IERC20Token)"
+ }
+ },
+ "id": 1539,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29017:29:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "28983:63:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1541,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "29065:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 1543,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 1542,
+ "name": "reserveTokenAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1535,
+ "src": "29077:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "29065:32:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1546,
+ "nodeType": "IfStatement",
+ "src": "29061:81:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1544,
+ "name": "reserveTokenAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1535,
+ "src": "29123:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "functionReturnParameters": 1517,
+ "id": 1545,
+ "nodeType": "Return",
+ "src": "29116:26:0"
+ }
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1530,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1528,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1525,
+ "src": "28945:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 1529,
+ "name": "reserveCount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1519,
+ "src": "28949:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "28945:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 1548,
+ "initializationExpression": {
+ "assignments": [
+ 1525
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1525,
+ "mutability": "mutable",
+ "name": "i",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1548,
+ "src": "28930:9:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1524,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "28930:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1527,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1526,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "28942:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "28930:13:0"
+ },
+ "loopExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1532,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "++",
+ "prefix": false,
+ "src": "28963:3:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "id": 1531,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1525,
+ "src": "28963:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 1533,
+ "nodeType": "ExpressionStatement",
+ "src": "28963:3:0"
+ },
+ "nodeType": "ForStatement",
+ "src": "28925:229:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1549,
+ "name": "ETH_RESERVE_ADDRESS",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 44,
+ "src": "29173:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "functionReturnParameters": 1517,
+ "id": 1550,
+ "nodeType": "Return",
+ "src": "29166:26:0"
+ }
+ ]
+ },
+ "documentation": null,
+ "id": 1552,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "getConverterEtherTokenAddress",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1514,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1513,
+ "mutability": "mutable",
+ "name": "_converter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1552,
+ "src": "28790:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1512,
+ "name": "IConverter",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13340,
+ "src": "28790:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "28789:23:0"
+ },
+ "returnParameters": {
+ "id": 1517,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1516,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1552,
+ "src": "28835:11:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1515,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "28835:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "28834:13:0"
+ },
+ "scope": 1976,
+ "src": "28751:449:0",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 1578,
+ "nodeType": "Block",
+ "src": "29474:224:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "id": 1564,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "!",
+ "prefix": true,
+ "src": "29489:20:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1561,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "29490:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 1563,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 1562,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1556,
+ "src": "29502:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "29490:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1567,
+ "nodeType": "IfStatement",
+ "src": "29485:52:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1565,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1556,
+ "src": "29531:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "functionReturnParameters": 1560,
+ "id": 1566,
+ "nodeType": "Return",
+ "src": "29524:13:0"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1569,
+ "name": "_converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1554,
+ "src": "29577:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1568,
+ "name": "isV28OrHigherConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1719,
+ "src": "29554:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$returns$_t_bool_$",
+ "typeString": "function (contract IConverter) view returns (bool)"
+ }
+ },
+ "id": 1570,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29554:34:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1573,
+ "nodeType": "IfStatement",
+ "src": "29550:79:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1571,
+ "name": "ETH_RESERVE_ADDRESS",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 44,
+ "src": "29610:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "functionReturnParameters": 1560,
+ "id": 1572,
+ "nodeType": "Return",
+ "src": "29603:26:0"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1575,
+ "name": "_converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1554,
+ "src": "29679:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1574,
+ "name": "getConverterEtherTokenAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1552,
+ "src": "29649:29:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$returns$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "function (contract IConverter) view returns (contract IERC20Token)"
+ }
+ },
+ "id": 1576,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29649:41:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "functionReturnParameters": 1560,
+ "id": 1577,
+ "nodeType": "Return",
+ "src": "29642:48:0"
+ }
+ ]
+ },
+ "documentation": null,
+ "id": 1579,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "getConverterTokenAddress",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1557,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1554,
+ "mutability": "mutable",
+ "name": "_converter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1579,
+ "src": "29396:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1553,
+ "name": "IConverter",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13340,
+ "src": "29396:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1556,
+ "mutability": "mutable",
+ "name": "_token",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1579,
+ "src": "29419:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1555,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "29419:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "29395:43:0"
+ },
+ "returnParameters": {
+ "id": 1560,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1559,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1579,
+ "src": "29461:11:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1558,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "29461:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "29460:13:0"
+ },
+ "scope": 1976,
+ "src": "29362:336:0",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 1587,
+ "mutability": "constant",
+ "name": "GET_RETURN_FUNC_SELECTOR",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1976,
+ "src": "29706:106:0",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ },
+ "typeName": {
+ "id": 1580,
+ "name": "bytes4",
+ "nodeType": "ElementaryTypeName",
+ "src": "29706:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "67657452657475726e28616464726573732c616464726573732c75696e7432353629",
+ "id": 1584,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29774:36:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_1e1401f8329fe5eb5c7e76277d3c971ffeee3a41a0eef7c00afeb0a286cef0af",
+ "typeString": "literal_string \"getReturn(address,address,uint256)\""
+ },
+ "value": "getReturn(address,address,uint256)"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_stringliteral_1e1401f8329fe5eb5c7e76277d3c971ffeee3a41a0eef7c00afeb0a286cef0af",
+ "typeString": "literal_string \"getReturn(address,address,uint256)\""
+ }
+ ],
+ "id": 1583,
+ "name": "keccak256",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -8,
+ "src": "29764:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_keccak256_pure$_t_bytes_memory_ptr_$returns$_t_bytes32_$",
+ "typeString": "function (bytes memory) pure returns (bytes32)"
+ }
+ },
+ "id": 1585,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29764:47:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ ],
+ "id": 1582,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "29757:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_bytes4_$",
+ "typeString": "type(bytes4)"
+ },
+ "typeName": {
+ "id": 1581,
+ "name": "bytes4",
+ "nodeType": "ElementaryTypeName",
+ "src": "29757:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1586,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29757:55:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ }
+ },
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 1663,
+ "nodeType": "Block",
+ "src": "30036:523:0",
+ "statements": [
+ {
+ "assignments": [
+ 1603
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1603,
+ "mutability": "mutable",
+ "name": "data",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1663,
+ "src": "30047:17:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes"
+ },
+ "typeName": {
+ "id": 1602,
+ "name": "bytes",
+ "nodeType": "ElementaryTypeName",
+ "src": "30047:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_storage_ptr",
+ "typeString": "bytes"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1611,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1606,
+ "name": "GET_RETURN_FUNC_SELECTOR",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1587,
+ "src": "30090:24:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1607,
+ "name": "_sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1591,
+ "src": "30116:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1608,
+ "name": "_targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1593,
+ "src": "30130:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1609,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1595,
+ "src": "30144:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1604,
+ "name": "abi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -1,
+ "src": "30067:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_abi",
+ "typeString": "abi"
+ }
+ },
+ "id": 1605,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "memberName": "encodeWithSelector",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "30067:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$",
+ "typeString": "function (bytes4) pure returns (bytes memory)"
+ }
+ },
+ "id": 1610,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30067:85:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "30047:105:0"
+ },
+ {
+ "assignments": [
+ 1613,
+ 1615
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1613,
+ "mutability": "mutable",
+ "name": "success",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1663,
+ "src": "30164:12:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 1612,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "30164:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1615,
+ "mutability": "mutable",
+ "name": "returnData",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1663,
+ "src": "30178:23:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes"
+ },
+ "typeName": {
+ "id": 1614,
+ "name": "bytes",
+ "nodeType": "ElementaryTypeName",
+ "src": "30178:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_storage_ptr",
+ "typeString": "bytes"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1623,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1621,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1603,
+ "src": "30231:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1618,
+ "name": "_dest",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1589,
+ "src": "30213:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1617,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "30205:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1616,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "30205:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1619,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30205:14:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "id": 1620,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "staticcall",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "30205:25:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_barestaticcall_view$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$",
+ "typeString": "function (bytes memory) view returns (bool,bytes memory)"
+ }
+ },
+ "id": 1622,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30205:31:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$",
+ "typeString": "tuple(bool,bytes memory)"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "30163:73:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "id": 1624,
+ "name": "success",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1613,
+ "src": "30253:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1658,
+ "nodeType": "IfStatement",
+ "src": "30249:277:0",
+ "trueBody": {
+ "id": 1657,
+ "nodeType": "Block",
+ "src": "30262:264:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1628,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1625,
+ "name": "returnData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1615,
+ "src": "30281:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ },
+ "id": 1626,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "30281:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3634",
+ "id": 1627,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "30302:2:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_64_by_1",
+ "typeString": "int_const 64"
+ },
+ "value": "64"
+ },
+ "src": "30281:23:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1640,
+ "nodeType": "IfStatement",
+ "src": "30277:113:0",
+ "trueBody": {
+ "id": 1639,
+ "nodeType": "Block",
+ "src": "30306:84:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1631,
+ "name": "returnData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1615,
+ "src": "30343:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 1633,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "30356:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_uint256_$",
+ "typeString": "type(uint256)"
+ },
+ "typeName": {
+ "id": 1632,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30356:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1635,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "30365:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_uint256_$",
+ "typeString": "type(uint256)"
+ },
+ "typeName": {
+ "id": 1634,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30365:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ }
+ ],
+ "id": 1636,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "30355:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_type$_t_uint256_$_$_t_type$_t_uint256_$_$",
+ "typeString": "tuple(type(uint256),type(uint256))"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ },
+ {
+ "typeIdentifier": "t_tuple$_t_type$_t_uint256_$_$_t_type$_t_uint256_$_$",
+ "typeString": "tuple(type(uint256),type(uint256))"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1629,
+ "name": "abi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -1,
+ "src": "30332:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_abi",
+ "typeString": "abi"
+ }
+ },
+ "id": 1630,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "memberName": "decode",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "30332:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_abidecode_pure$__$returns$__$",
+ "typeString": "function () pure"
+ }
+ },
+ "id": 1637,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30332:42:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "functionReturnParameters": 1601,
+ "id": 1638,
+ "nodeType": "Return",
+ "src": "30325:49:0"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1644,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1641,
+ "name": "returnData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1615,
+ "src": "30410:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ },
+ "id": 1642,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "30410:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3332",
+ "id": 1643,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "30431:2:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_32_by_1",
+ "typeString": "int_const 32"
+ },
+ "value": "32"
+ },
+ "src": "30410:23:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1656,
+ "nodeType": "IfStatement",
+ "src": "30406:109:0",
+ "trueBody": {
+ "id": 1655,
+ "nodeType": "Block",
+ "src": "30435:80:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1647,
+ "name": "returnData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1615,
+ "src": "30473:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 1649,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "30486:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_uint256_$",
+ "typeString": "type(uint256)"
+ },
+ "typeName": {
+ "id": 1648,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30486:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ }
+ ],
+ "id": 1650,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "30485:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_uint256_$",
+ "typeString": "type(uint256)"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ },
+ {
+ "typeIdentifier": "t_type$_t_uint256_$",
+ "typeString": "type(uint256)"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1645,
+ "name": "abi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -1,
+ "src": "30462:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_abi",
+ "typeString": "abi"
+ }
+ },
+ "id": 1646,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "memberName": "decode",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "30462:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_abidecode_pure$__$returns$__$",
+ "typeString": "function () pure"
+ }
+ },
+ "id": 1651,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30462:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1652,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "30497:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "id": 1653,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "30461:38:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_rational_0_by_1_$",
+ "typeString": "tuple(uint256,int_const 0)"
+ }
+ },
+ "functionReturnParameters": 1601,
+ "id": 1654,
+ "nodeType": "Return",
+ "src": "30454:45:0"
+ }
+ ]
+ }
+ }
+ ]
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1659,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "30546:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1660,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "30549:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "id": 1661,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "30545:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_rational_0_by_1_$_t_rational_0_by_1_$",
+ "typeString": "tuple(int_const 0,int_const 0)"
+ }
+ },
+ "functionReturnParameters": 1601,
+ "id": 1662,
+ "nodeType": "Return",
+ "src": "30538:13:0"
+ }
+ ]
+ },
+ "documentation": null,
+ "id": 1664,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "getReturn",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1596,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1589,
+ "mutability": "mutable",
+ "name": "_dest",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1664,
+ "src": "29908:16:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1588,
+ "name": "IConverter",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13340,
+ "src": "29908:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1591,
+ "mutability": "mutable",
+ "name": "_sourceToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1664,
+ "src": "29926:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1590,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "29926:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1593,
+ "mutability": "mutable",
+ "name": "_targetToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1664,
+ "src": "29952:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1592,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "29952:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1595,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1664,
+ "src": "29978:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1594,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "29978:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "29907:87:0"
+ },
+ "returnParameters": {
+ "id": 1601,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1598,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1664,
+ "src": "30018:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1597,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30018:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1600,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1664,
+ "src": "30027:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1599,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30027:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "30017:18:0"
+ },
+ "scope": 1976,
+ "src": "29889:670:0",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "constant": true,
+ "id": 1672,
+ "mutability": "constant",
+ "name": "IS_V28_OR_HIGHER_FUNC_SELECTOR",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1976,
+ "src": "30567:93:0",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ },
+ "typeName": {
+ "id": 1665,
+ "name": "bytes4",
+ "nodeType": "ElementaryTypeName",
+ "src": "30567:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "69735632384f724869676865722829",
+ "id": 1669,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "30641:17:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_d260529c8620a59d78f2e58cfd1294673bb6cba228ad1f34ac7731003ab870dd",
+ "typeString": "literal_string \"isV28OrHigher()\""
+ },
+ "value": "isV28OrHigher()"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_stringliteral_d260529c8620a59d78f2e58cfd1294673bb6cba228ad1f34ac7731003ab870dd",
+ "typeString": "literal_string \"isV28OrHigher()\""
+ }
+ ],
+ "id": 1668,
+ "name": "keccak256",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -8,
+ "src": "30631:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_keccak256_pure$_t_bytes_memory_ptr_$returns$_t_bytes32_$",
+ "typeString": "function (bytes memory) pure returns (bytes32)"
+ }
+ },
+ "id": 1670,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30631:28:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ ],
+ "id": 1667,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "30624:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_bytes4_$",
+ "typeString": "type(bytes4)"
+ },
+ "typeName": {
+ "id": 1666,
+ "name": "bytes4",
+ "nodeType": "ElementaryTypeName",
+ "src": "30624:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1671,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30624:36:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ }
+ },
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 1718,
+ "nodeType": "Block",
+ "src": "30917:336:0",
+ "statements": [
+ {
+ "assignments": [
+ 1680
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1680,
+ "mutability": "mutable",
+ "name": "data",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1718,
+ "src": "30928:17:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes"
+ },
+ "typeName": {
+ "id": 1679,
+ "name": "bytes",
+ "nodeType": "ElementaryTypeName",
+ "src": "30928:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_storage_ptr",
+ "typeString": "bytes"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1685,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1683,
+ "name": "IS_V28_OR_HIGHER_FUNC_SELECTOR",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1672,
+ "src": "30971:30:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1681,
+ "name": "abi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -1,
+ "src": "30948:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_abi",
+ "typeString": "abi"
+ }
+ },
+ "id": 1682,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "memberName": "encodeWithSelector",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "30948:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$",
+ "typeString": "function (bytes4) pure returns (bytes memory)"
+ }
+ },
+ "id": 1684,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30948:54:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "30928:74:0"
+ },
+ {
+ "assignments": [
+ 1687,
+ 1689
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1687,
+ "mutability": "mutable",
+ "name": "success",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1718,
+ "src": "31014:12:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 1686,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "31014:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1689,
+ "mutability": "mutable",
+ "name": "returnData",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1718,
+ "src": "31028:23:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes"
+ },
+ "typeName": {
+ "id": 1688,
+ "name": "bytes",
+ "nodeType": "ElementaryTypeName",
+ "src": "31028:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_storage_ptr",
+ "typeString": "bytes"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1699,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1697,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1680,
+ "src": "31099:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1692,
+ "name": "_converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1674,
+ "src": "31063:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1691,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "31055:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1690,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "31055:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1693,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "31055:19:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "id": 1694,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "staticcall",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "31055:30:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_barestaticcall_view$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$",
+ "typeString": "function (bytes memory) view returns (bool,bytes memory)"
+ }
+ },
+ "id": 1696,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "names": [
+ "gas"
+ ],
+ "nodeType": "FunctionCallOptions",
+ "options": [
+ {
+ "argumentTypes": null,
+ "hexValue": "34303030",
+ "id": 1695,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "31092:4:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4000_by_1",
+ "typeString": "int_const 4000"
+ },
+ "value": "4000"
+ }
+ ],
+ "src": "31055:43:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_barestaticcall_view$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$gas",
+ "typeString": "function (bytes memory) view returns (bool,bytes memory)"
+ }
+ },
+ "id": 1698,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "31055:49:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$",
+ "typeString": "tuple(bool,bytes memory)"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "31013:91:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 1705,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1700,
+ "name": "success",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1687,
+ "src": "31121:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1704,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1701,
+ "name": "returnData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1689,
+ "src": "31132:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ },
+ "id": 1702,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "31132:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3332",
+ "id": 1703,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "31153:2:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_32_by_1",
+ "typeString": "int_const 32"
+ },
+ "value": "32"
+ },
+ "src": "31132:23:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "31121:34:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1715,
+ "nodeType": "IfStatement",
+ "src": "31117:104:0",
+ "trueBody": {
+ "id": 1714,
+ "nodeType": "Block",
+ "src": "31157:64:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1708,
+ "name": "returnData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1689,
+ "src": "31190:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 1710,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "31203:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_bool_$",
+ "typeString": "type(bool)"
+ },
+ "typeName": {
+ "id": 1709,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "31203:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ }
+ ],
+ "id": 1711,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "31202:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_bool_$",
+ "typeString": "type(bool)"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ },
+ {
+ "typeIdentifier": "t_type$_t_bool_$",
+ "typeString": "type(bool)"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1706,
+ "name": "abi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -1,
+ "src": "31179:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_abi",
+ "typeString": "abi"
+ }
+ },
+ "id": 1707,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "memberName": "decode",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "31179:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_abidecode_pure$__$returns$__$",
+ "typeString": "function () pure"
+ }
+ },
+ "id": 1712,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "31179:30:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "functionReturnParameters": 1678,
+ "id": 1713,
+ "nodeType": "Return",
+ "src": "31172:37:0"
+ }
+ ]
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "hexValue": "66616c7365",
+ "id": 1716,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "31240:5:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "false"
+ },
+ "functionReturnParameters": 1678,
+ "id": 1717,
+ "nodeType": "Return",
+ "src": "31233:12:0"
+ }
+ ]
+ },
+ "documentation": null,
+ "id": 1719,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "isV28OrHigherConverter",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1675,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1674,
+ "mutability": "mutable",
+ "name": "_converter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1719,
+ "src": "30865:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1673,
+ "name": "IConverter",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13340,
+ "src": "30865:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "30864:23:0"
+ },
+ "returnParameters": {
+ "id": 1678,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1677,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1719,
+ "src": "30911:4:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 1676,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "30911:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "30910:6:0"
+ },
+ "scope": 1976,
+ "src": "30833:420:0",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 1739,
+ "nodeType": "Block",
+ "src": "31432:57:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1733,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1723,
+ "src": "31462:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1734,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1725,
+ "src": "31469:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1732,
+ "name": "rateByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 462,
+ "src": "31451:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256) view returns (uint256)"
+ }
+ },
+ "id": 1735,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "31451:26:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1736,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "31479:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "id": 1737,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "31450:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_rational_0_by_1_$",
+ "typeString": "tuple(uint256,int_const 0)"
+ }
+ },
+ "functionReturnParameters": 1731,
+ "id": 1738,
+ "nodeType": "Return",
+ "src": "31443:38:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1720,
+ "nodeType": "StructuredDocumentation",
+ "src": "31261:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "0c8496cc",
+ "id": 1740,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "getReturnByPath",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1726,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1723,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1740,
+ "src": "31352:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1721,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "31352:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1722,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "31352:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1725,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1740,
+ "src": "31376:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1724,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31376:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "31351:41:0"
+ },
+ "returnParameters": {
+ "id": 1731,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1728,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1740,
+ "src": "31414:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1727,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31414:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1730,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1740,
+ "src": "31423:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1729,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31423:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "31413:18:0"
+ },
+ "scope": 1976,
+ "src": "31327:162:0",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 1768,
+ "nodeType": "Block",
+ "src": "31674:94:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1754,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1744,
+ "src": "31706:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1755,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1746,
+ "src": "31713:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1756,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1748,
+ "src": "31722:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1759,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "31742:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1758,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "31734:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1757,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "31734:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1760,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "31734:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1763,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "31754:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1762,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "31746:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1761,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "31746:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1764,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "31746:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1765,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "31758:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1753,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "31692:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 1766,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "31692:68:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 1752,
+ "id": 1767,
+ "nodeType": "Return",
+ "src": "31685:75:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1741,
+ "nodeType": "StructuredDocumentation",
+ "src": "31497:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "f3898a97",
+ "id": 1769,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "convert",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1749,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1744,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1769,
+ "src": "31580:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1742,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "31580:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1743,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "31580:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1746,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1769,
+ "src": "31604:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1745,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31604:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1748,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1769,
+ "src": "31621:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1747,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31621:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "31579:61:0"
+ },
+ "returnParameters": {
+ "id": 1752,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1751,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1769,
+ "src": "31665:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1750,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31665:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "31664:9:0"
+ },
+ "scope": 1976,
+ "src": "31563:205:0",
+ "stateMutability": "payable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 1798,
+ "nodeType": "Block",
+ "src": "32088:113:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1787,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1773,
+ "src": "32120:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1788,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1775,
+ "src": "32127:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1789,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1777,
+ "src": "32136:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1792,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "32156:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1791,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "32148:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1790,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "32148:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1793,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "32148:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1794,
+ "name": "_affiliateAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1779,
+ "src": "32160:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1795,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1781,
+ "src": "32179:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1786,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "32106:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 1796,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "32106:87:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 1785,
+ "id": 1797,
+ "nodeType": "Return",
+ "src": "32099:94:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1770,
+ "nodeType": "StructuredDocumentation",
+ "src": "31776:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "569706eb",
+ "id": 1799,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "convert2",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1782,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1773,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1799,
+ "src": "31870:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1771,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "31870:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1772,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "31870:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1775,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1799,
+ "src": "31903:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1774,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31903:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1777,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1799,
+ "src": "31929:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1776,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31929:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1779,
+ "mutability": "mutable",
+ "name": "_affiliateAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1799,
+ "src": "31958:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 1778,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "31958:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1781,
+ "mutability": "mutable",
+ "name": "_affiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1799,
+ "src": "31994:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1780,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31994:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "31859:163:0"
+ },
+ "returnParameters": {
+ "id": 1785,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1784,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1799,
+ "src": "32074:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1783,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32074:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "32073:9:0"
+ },
+ "scope": 1976,
+ "src": "31842:359:0",
+ "stateMutability": "payable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 1826,
+ "nodeType": "Block",
+ "src": "32419:96:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1815,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1803,
+ "src": "32451:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1816,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1805,
+ "src": "32458:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1817,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1807,
+ "src": "32467:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1818,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1809,
+ "src": "32479:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1821,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "32501:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1820,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "32493:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1819,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "32493:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1822,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "32493:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1823,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "32505:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1814,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "32437:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 1824,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "32437:70:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 1813,
+ "id": 1825,
+ "nodeType": "Return",
+ "src": "32430:77:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1800,
+ "nodeType": "StructuredDocumentation",
+ "src": "32209:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "c98fefed",
+ "id": 1827,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "convertFor",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1810,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1803,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1827,
+ "src": "32295:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1801,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "32295:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1802,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "32295:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1805,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1827,
+ "src": "32319:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1804,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32319:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1807,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1827,
+ "src": "32336:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1806,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32336:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1809,
+ "mutability": "mutable",
+ "name": "_beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1827,
+ "src": "32356:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 1808,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "32356:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "32294:91:0"
+ },
+ "returnParameters": {
+ "id": 1813,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1812,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1827,
+ "src": "32410:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1811,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32410:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "32409:9:0"
+ },
+ "scope": 1976,
+ "src": "32275:240:0",
+ "stateMutability": "payable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 1858,
+ "nodeType": "Block",
+ "src": "32914:115:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1850,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1831,
+ "src": "32946:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1851,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1833,
+ "src": "32953:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1852,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1835,
+ "src": "32962:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1853,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1837,
+ "src": "32974:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1854,
+ "name": "_affiliateAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1839,
+ "src": "32988:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1855,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1841,
+ "src": "33007:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1849,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "32932:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 1856,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "32932:89:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 1848,
+ "id": 1857,
+ "nodeType": "Return",
+ "src": "32925:96:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1828,
+ "nodeType": "StructuredDocumentation",
+ "src": "32523:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "ab6214ce",
+ "id": 1859,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1844,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1835,
+ "src": "32870:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 1845,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 1843,
+ "name": "greaterThanZero",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22595,
+ "src": "32854:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$_t_uint256_$",
+ "typeString": "modifier (uint256)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "32854:27:0"
+ }
+ ],
+ "name": "convertFor2",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1842,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1831,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1859,
+ "src": "32620:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1829,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "32620:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1830,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "32620:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1833,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1859,
+ "src": "32653:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1832,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32653:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1835,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1859,
+ "src": "32679:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1834,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32679:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1837,
+ "mutability": "mutable",
+ "name": "_beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1859,
+ "src": "32708:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 1836,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "32708:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1839,
+ "mutability": "mutable",
+ "name": "_affiliateAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1859,
+ "src": "32747:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 1838,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "32747:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1841,
+ "mutability": "mutable",
+ "name": "_affiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1859,
+ "src": "32783:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1840,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32783:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "32609:202:0"
+ },
+ "returnParameters": {
+ "id": 1848,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1847,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1859,
+ "src": "32900:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1846,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32900:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "32899:9:0"
+ },
+ "scope": 1976,
+ "src": "32589:440:0",
+ "stateMutability": "payable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 1887,
+ "nodeType": "Block",
+ "src": "33214:94:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1873,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1863,
+ "src": "33246:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1874,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1865,
+ "src": "33253:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1875,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1867,
+ "src": "33262:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1878,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33282:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1877,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "33274:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1876,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "33274:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1879,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33274:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1882,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33294:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1881,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "33286:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1880,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "33286:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1883,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33286:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1884,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33298:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1872,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "33232:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 1885,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33232:68:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 1871,
+ "id": 1886,
+ "nodeType": "Return",
+ "src": "33225:75:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1860,
+ "nodeType": "StructuredDocumentation",
+ "src": "33037:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "c7ba24bc",
+ "id": 1888,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "claimAndConvert",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1868,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1863,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1888,
+ "src": "33128:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1861,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "33128:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1862,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "33128:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1865,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1888,
+ "src": "33152:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1864,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33152:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1867,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1888,
+ "src": "33169:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1866,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33169:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "33127:61:0"
+ },
+ "returnParameters": {
+ "id": 1871,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1870,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1888,
+ "src": "33205:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1869,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33205:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "33204:9:0"
+ },
+ "scope": 1976,
+ "src": "33103:205:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 1917,
+ "nodeType": "Block",
+ "src": "33619:113:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1906,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1892,
+ "src": "33651:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1907,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1894,
+ "src": "33658:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1908,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1896,
+ "src": "33667:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1911,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33687:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1910,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "33679:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1909,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "33679:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1912,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33679:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1913,
+ "name": "_affiliateAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1898,
+ "src": "33691:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1914,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1900,
+ "src": "33710:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1905,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "33637:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 1915,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33637:87:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 1904,
+ "id": 1916,
+ "nodeType": "Return",
+ "src": "33630:94:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1889,
+ "nodeType": "StructuredDocumentation",
+ "src": "33316:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "e57738e5",
+ "id": 1918,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "claimAndConvert2",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1901,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1892,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1918,
+ "src": "33418:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1890,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "33418:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1891,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "33418:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1894,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1918,
+ "src": "33451:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1893,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33451:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1896,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1918,
+ "src": "33477:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1895,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33477:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1898,
+ "mutability": "mutable",
+ "name": "_affiliateAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1918,
+ "src": "33506:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 1897,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "33506:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1900,
+ "mutability": "mutable",
+ "name": "_affiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1918,
+ "src": "33542:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1899,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33542:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "33407:163:0"
+ },
+ "returnParameters": {
+ "id": 1904,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1903,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1918,
+ "src": "33605:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1902,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33605:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "33604:9:0"
+ },
+ "scope": 1976,
+ "src": "33382:350:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 1945,
+ "nodeType": "Block",
+ "src": "33950:96:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1934,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1922,
+ "src": "33982:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1935,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1924,
+ "src": "33989:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1936,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1926,
+ "src": "33998:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1937,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1928,
+ "src": "34010:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1940,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "34032:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1939,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "34024:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1938,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "34024:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1941,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "34024:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1942,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "34036:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1933,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "33968:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 1943,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33968:70:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 1932,
+ "id": 1944,
+ "nodeType": "Return",
+ "src": "33961:77:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1919,
+ "nodeType": "StructuredDocumentation",
+ "src": "33740:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "b1e9932b",
+ "id": 1946,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "claimAndConvertFor",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1929,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1922,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1946,
+ "src": "33834:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1920,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "33834:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1921,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "33834:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1924,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1946,
+ "src": "33858:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1923,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33858:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1926,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1946,
+ "src": "33875:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1925,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33875:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1928,
+ "mutability": "mutable",
+ "name": "_beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1946,
+ "src": "33895:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 1927,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "33895:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "33833:91:0"
+ },
+ "returnParameters": {
+ "id": 1932,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1931,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1946,
+ "src": "33941:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1930,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33941:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "33940:9:0"
+ },
+ "scope": 1976,
+ "src": "33806:240:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 1974,
+ "nodeType": "Block",
+ "src": "34399:115:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1966,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1950,
+ "src": "34431:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1967,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1952,
+ "src": "34438:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1968,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1954,
+ "src": "34447:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1969,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1956,
+ "src": "34459:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1970,
+ "name": "_affiliateAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1958,
+ "src": "34473:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1971,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1960,
+ "src": "34492:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1965,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "34417:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 1972,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "34417:89:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 1964,
+ "id": 1973,
+ "nodeType": "Return",
+ "src": "34410:96:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1947,
+ "nodeType": "StructuredDocumentation",
+ "src": "34054:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "2978c10e",
+ "id": 1975,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "claimAndConvertFor2",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1961,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1950,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1975,
+ "src": "34159:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1948,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "34159:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1949,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "34159:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1952,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1975,
+ "src": "34192:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1951,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "34192:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1954,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1975,
+ "src": "34218:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1953,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "34218:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1956,
+ "mutability": "mutable",
+ "name": "_beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1975,
+ "src": "34247:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 1955,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "34247:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1958,
+ "mutability": "mutable",
+ "name": "_affiliateAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1975,
+ "src": "34286:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 1957,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "34286:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1960,
+ "mutability": "mutable",
+ "name": "_affiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1975,
+ "src": "34322:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1959,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "34322:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "34148:202:0"
+ },
+ "returnParameters": {
+ "id": 1964,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1963,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1975,
+ "src": "34385:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1962,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "34385:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "34384:9:0"
+ },
+ "scope": 1976,
+ "src": "34120:394:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ }
+ ],
+ "scope": 1977,
+ "src": "1956:32561:0"
+ }
+ ],
+ "src": "52:34467:0"
+ },
+ "legacyAST": {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/BancorNetwork.sol",
+ "exportedSymbols": {
+ "BancorNetwork": [
+ 1976
+ ],
+ "ILegacyConverter": [
+ 26
+ ]
+ },
+ "id": 1977,
+ "license": "SEE LICENSE IN LICENSE",
+ "nodeType": "SourceUnit",
+ "nodes": [
+ {
+ "id": 1,
+ "literals": [
+ "solidity",
+ "0.6",
+ ".12"
+ ],
+ "nodeType": "PragmaDirective",
+ "src": "52:23:0"
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/IConversionPathFinder.sol",
+ "file": "./IConversionPathFinder.sol",
+ "id": 2,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 2547,
+ "src": "77:37:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IConverter.sol",
+ "file": "./converter/interfaces/IConverter.sol",
+ "id": 3,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 13341,
+ "src": "116:47:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IConverterAnchor.sol",
+ "file": "./converter/interfaces/IConverterAnchor.sol",
+ "id": 4,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 13350,
+ "src": "165:53:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IBancorFormula.sol",
+ "file": "./converter/interfaces/IBancorFormula.sol",
+ "id": 5,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 13178,
+ "src": "220:51:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/ContractRegistryClient.sol",
+ "file": "./utility/ContractRegistryClient.sol",
+ "id": 6,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 21720,
+ "src": "273:46:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/ReentrancyGuard.sol",
+ "file": "./utility/ReentrancyGuard.sol",
+ "id": 7,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 22243,
+ "src": "321:39:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/TokenHolder.sol",
+ "file": "./utility/TokenHolder.sol",
+ "id": 8,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 22576,
+ "src": "362:35:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/SafeMath.sol",
+ "file": "./utility/SafeMath.sol",
+ "id": 9,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 22355,
+ "src": "399:32:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/interfaces/IEtherToken.sol",
+ "file": "./token/interfaces/IEtherToken.sol",
+ "id": 10,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 21154,
+ "src": "433:44:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/interfaces/ISmartToken.sol",
+ "file": "./token/interfaces/ISmartToken.sol",
+ "id": 11,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 21183,
+ "src": "479:44:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/bancorx/interfaces/IBancorX.sol",
+ "file": "./bancorx/interfaces/IBancorX.sol",
+ "id": 12,
+ "nodeType": "ImportDirective",
+ "scope": 1977,
+ "sourceUnit": 3552,
+ "src": "525:43:0",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "abstract": false,
+ "baseContracts": [],
+ "contractDependencies": [],
+ "contractKind": "interface",
+ "documentation": null,
+ "fullyImplemented": false,
+ "id": 26,
+ "linearizedBaseContracts": [
+ 26
+ ],
+ "name": "ILegacyConverter",
+ "nodeType": "ContractDefinition",
+ "nodes": [
+ {
+ "body": null,
+ "documentation": null,
+ "functionSelector": "5e5144eb",
+ "id": 25,
+ "implemented": false,
+ "kind": "function",
+ "modifiers": [],
+ "name": "change",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 21,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 14,
+ "mutability": "mutable",
+ "name": "_sourceToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 25,
+ "src": "683:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 13,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "683:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 16,
+ "mutability": "mutable",
+ "name": "_targetToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 25,
+ "src": "709:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 15,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "709:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 18,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 25,
+ "src": "735:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 17,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "735:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 20,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 25,
+ "src": "752:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 19,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "752:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "682:89:0"
+ },
+ "returnParameters": {
+ "id": 24,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 23,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 25,
+ "src": "790:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 22,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "790:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "789:9:0"
+ },
+ "scope": 26,
+ "src": "667:132:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "external"
+ }
+ ],
+ "scope": 1977,
+ "src": "633:169:0"
+ },
+ {
+ "abstract": false,
+ "baseContracts": [
+ {
+ "arguments": null,
+ "baseName": {
+ "contractScope": null,
+ "id": 28,
+ "name": "TokenHolder",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 22575,
+ "src": "1982:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_TokenHolder_$22575",
+ "typeString": "contract TokenHolder"
+ }
+ },
+ "id": 29,
+ "nodeType": "InheritanceSpecifier",
+ "src": "1982:11:0"
+ },
+ {
+ "arguments": null,
+ "baseName": {
+ "contractScope": null,
+ "id": 30,
+ "name": "ContractRegistryClient",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21719,
+ "src": "1995:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_ContractRegistryClient_$21719",
+ "typeString": "contract ContractRegistryClient"
+ }
+ },
+ "id": 31,
+ "nodeType": "InheritanceSpecifier",
+ "src": "1995:22:0"
+ },
+ {
+ "arguments": null,
+ "baseName": {
+ "contractScope": null,
+ "id": 32,
+ "name": "ReentrancyGuard",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 22242,
+ "src": "2019:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_ReentrancyGuard_$22242",
+ "typeString": "contract ReentrancyGuard"
+ }
+ },
+ "id": 33,
+ "nodeType": "InheritanceSpecifier",
+ "src": "2019:15:0"
+ }
+ ],
+ "contractDependencies": [
+ 21719,
+ 21818,
+ 22242,
+ 22526,
+ 22575,
+ 22661,
+ 22847,
+ 22907
+ ],
+ "contractKind": "contract",
+ "documentation": {
+ "id": 27,
+ "nodeType": "StructuredDocumentation",
+ "src": "806:1148:0",
+ "text": " @dev The BancorNetwork contract is the main entry point for Bancor token conversions.\n It also allows for the conversion of any token in the Bancor Network to any other token in a single\n transaction by providing a conversion path.\n A note on Conversion Path: Conversion path is a data structure that is used when converting a token\n to another token in the Bancor Network, when the conversion cannot necessarily be done by a single\n converter and might require multiple 'hops'.\n The path defines which converters should be used and what kind of conversion should be done in each step.\n The path format doesn't include complex structure; instead, it is represented by a single array\n in which each 'hop' is represented by a 2-tuple - converter anchor & target token.\n In addition, the first element is always the source token.\n The converter anchor is only used as a pointer to a converter (since converter addresses are more\n likely to change as opposed to anchor addresses).\n Format:\n [source token, converter anchor, target token, converter anchor, target token...]"
+ },
+ "fullyImplemented": true,
+ "id": 1976,
+ "linearizedBaseContracts": [
+ 1976,
+ 22242,
+ 21719,
+ 22575,
+ 22661,
+ 21818,
+ 22526,
+ 22907,
+ 22847
+ ],
+ "name": "BancorNetwork",
+ "nodeType": "ContractDefinition",
+ "nodes": [
+ {
+ "id": 36,
+ "libraryName": {
+ "contractScope": null,
+ "id": 34,
+ "name": "SafeMath",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 22354,
+ "src": "2048:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_SafeMath_$22354",
+ "typeString": "library SafeMath"
+ }
+ },
+ "nodeType": "UsingForDirective",
+ "src": "2042:27:0",
+ "typeName": {
+ "id": 35,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "2061:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ },
+ {
+ "constant": true,
+ "id": 39,
+ "mutability": "constant",
+ "name": "PPM_RESOLUTION",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1976,
+ "src": "2077:49:0",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 37,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "2077:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "31303030303030",
+ "id": 38,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "2119:7:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1000000_by_1",
+ "typeString": "int_const 1000000"
+ },
+ "value": "1000000"
+ },
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 44,
+ "mutability": "constant",
+ "name": "ETH_RESERVE_ADDRESS",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1976,
+ "src": "2133:106:0",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 40,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "2133:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "307845656565654565656545654565654565456545656545454565656565456565656565656545456545",
+ "id": 42,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "2196:42:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "value": "0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "id": 41,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "2184:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 43,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "2184:55:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "visibility": "private"
+ },
+ {
+ "canonicalName": "BancorNetwork.ConversionStep",
+ "id": 59,
+ "members": [
+ {
+ "constant": false,
+ "id": 46,
+ "mutability": "mutable",
+ "name": "converter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 59,
+ "src": "2281:20:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 45,
+ "name": "IConverter",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13340,
+ "src": "2281:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 48,
+ "mutability": "mutable",
+ "name": "anchor",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 59,
+ "src": "2312:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 47,
+ "name": "IConverterAnchor",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13349,
+ "src": "2312:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 50,
+ "mutability": "mutable",
+ "name": "sourceToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 59,
+ "src": "2346:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 49,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "2346:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 52,
+ "mutability": "mutable",
+ "name": "targetToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 59,
+ "src": "2380:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 51,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "2380:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 54,
+ "mutability": "mutable",
+ "name": "beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 59,
+ "src": "2414:27:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 53,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "2414:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 56,
+ "mutability": "mutable",
+ "name": "isV28OrHigherConverter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 59,
+ "src": "2452:27:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 55,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "2452:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 58,
+ "mutability": "mutable",
+ "name": "processAffiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 59,
+ "src": "2490:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 57,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "2490:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "name": "ConversionStep",
+ "nodeType": "StructDefinition",
+ "scope": 1976,
+ "src": "2248:274:0",
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "5d732ff2",
+ "id": 62,
+ "mutability": "mutable",
+ "name": "maxAffiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1976,
+ "src": "2530:38:0",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 60,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "2530:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "3330303030",
+ "id": 61,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "2563:5:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_30000_by_1",
+ "typeString": "int_const 30000"
+ },
+ "value": "30000"
+ },
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "8077ccf7",
+ "id": 66,
+ "mutability": "mutable",
+ "name": "etherTokens",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1976,
+ "src": "2606:48:0",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ },
+ "typeName": {
+ "id": 65,
+ "keyType": {
+ "contractScope": null,
+ "id": 63,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "2615:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "Mapping",
+ "src": "2606:29:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ },
+ "valueType": {
+ "id": 64,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "2630:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ }
+ },
+ "value": null,
+ "visibility": "public"
+ },
+ {
+ "anonymous": false,
+ "documentation": {
+ "id": 67,
+ "nodeType": "StructuredDocumentation",
+ "src": "2703:441:0",
+ "text": " @dev triggered when a conversion between two tokens occurs\n @param _smartToken anchor governed by the converter\n @param _fromToken source ERC20 token\n @param _toToken target ERC20 token\n @param _fromAmount amount converted, in the source token\n @param _toAmount amount returned, minus conversion fee\n @param _trader wallet that initiated the trade"
+ },
+ "id": 81,
+ "name": "Conversion",
+ "nodeType": "EventDefinition",
+ "parameters": {
+ "id": 80,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 69,
+ "indexed": true,
+ "mutability": "mutable",
+ "name": "_smartToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 81,
+ "src": "3177:36:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 68,
+ "name": "IConverterAnchor",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13349,
+ "src": "3177:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 71,
+ "indexed": true,
+ "mutability": "mutable",
+ "name": "_fromToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 81,
+ "src": "3224:30:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 70,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "3224:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 73,
+ "indexed": true,
+ "mutability": "mutable",
+ "name": "_toToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 81,
+ "src": "3265:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 72,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "3265:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 75,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_fromAmount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 81,
+ "src": "3304:19:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 74,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "3304:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 77,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_toAmount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 81,
+ "src": "3334:17:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 76,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "3334:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 79,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_trader",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 81,
+ "src": "3362:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 78,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "3362:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "3166:218:0"
+ },
+ "src": "3150:235:0"
+ },
+ {
+ "body": {
+ "id": 96,
+ "nodeType": "Block",
+ "src": "3625:58:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 94,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 90,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "3636:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 92,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 91,
+ "name": "ETH_RESERVE_ADDRESS",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 44,
+ "src": "3648:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "3636:32:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "74727565",
+ "id": 93,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "3671:4:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "true"
+ },
+ "src": "3636:39:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 95,
+ "nodeType": "ExpressionStatement",
+ "src": "3636:39:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 82,
+ "nodeType": "StructuredDocumentation",
+ "src": "3393:144:0",
+ "text": " @dev initializes a new BancorNetwork instance\n @param _registry address of a contract registry contract"
+ },
+ "id": 97,
+ "implemented": true,
+ "kind": "constructor",
+ "modifiers": [
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 87,
+ "name": "_registry",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 84,
+ "src": "3607:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IContractRegistry_$22831",
+ "typeString": "contract IContractRegistry"
+ }
+ }
+ ],
+ "id": 88,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 86,
+ "name": "ContractRegistryClient",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21719,
+ "src": "3584:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_ContractRegistryClient_$21719_$",
+ "typeString": "type(contract ContractRegistryClient)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "3584:33:0"
+ }
+ ],
+ "name": "",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 85,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 84,
+ "mutability": "mutable",
+ "name": "_registry",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 97,
+ "src": "3555:27:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IContractRegistry_$22831",
+ "typeString": "contract IContractRegistry"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 83,
+ "name": "IContractRegistry",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 22831,
+ "src": "3555:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IContractRegistry_$22831",
+ "typeString": "contract IContractRegistry"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "3554:29:0"
+ },
+ "returnParameters": {
+ "id": 89,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "3625:0:0"
+ },
+ "scope": 1976,
+ "src": "3543:140:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 116,
+ "nodeType": "Block",
+ "src": "3935:136:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 108,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 106,
+ "name": "_maxAffiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 100,
+ "src": "3954:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 107,
+ "name": "PPM_RESOLUTION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 39,
+ "src": "3974:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "3954:34:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f414646494c494154455f464545",
+ "id": 109,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "3990:27:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_5421a6ae0116cbc310697cd7899b77d6a7bc1fb10cd896c84c63fd20f8fbd382",
+ "typeString": "literal_string \"ERR_INVALID_AFFILIATE_FEE\""
+ },
+ "value": "ERR_INVALID_AFFILIATE_FEE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_5421a6ae0116cbc310697cd7899b77d6a7bc1fb10cd896c84c63fd20f8fbd382",
+ "typeString": "literal_string \"ERR_INVALID_AFFILIATE_FEE\""
+ }
+ ],
+ "id": 105,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "3946:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 110,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "3946:72:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 111,
+ "nodeType": "ExpressionStatement",
+ "src": "3946:72:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 114,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 112,
+ "name": "maxAffiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 62,
+ "src": "4029:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 113,
+ "name": "_maxAffiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 100,
+ "src": "4047:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "4029:34:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 115,
+ "nodeType": "ExpressionStatement",
+ "src": "4029:34:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 98,
+ "nodeType": "StructuredDocumentation",
+ "src": "3691:144:0",
+ "text": " @dev allows the owner to update the maximum affiliate-fee\n @param _maxAffiliateFee maximum affiliate-fee"
+ },
+ "functionSelector": "f3bc7d2a",
+ "id": 117,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [
+ {
+ "arguments": null,
+ "id": 103,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 102,
+ "name": "ownerOnly",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21754,
+ "src": "3920:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$__$",
+ "typeString": "modifier ()"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "3920:9:0"
+ }
+ ],
+ "name": "setMaxAffiliateFee",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 101,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 100,
+ "mutability": "mutable",
+ "name": "_maxAffiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 117,
+ "src": "3869:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 99,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "3869:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "3868:26:0"
+ },
+ "returnParameters": {
+ "id": 104,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "3935:0:0"
+ },
+ "scope": 1976,
+ "src": "3841:230:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 145,
+ "nodeType": "Block",
+ "src": "4474:50:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 143,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 139,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "4485:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 141,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 140,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 120,
+ "src": "4497:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "4485:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 142,
+ "name": "_register",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 122,
+ "src": "4507:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "4485:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 144,
+ "nodeType": "ExpressionStatement",
+ "src": "4485:31:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 118,
+ "nodeType": "StructuredDocumentation",
+ "src": "4079:212:0",
+ "text": " @dev allows the owner to register/unregister ether tokens\n @param _token ether token contract address\n @param _register true to register, false to unregister"
+ },
+ "functionSelector": "02ef521e",
+ "id": 146,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [
+ {
+ "arguments": null,
+ "id": 125,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 124,
+ "name": "ownerOnly",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21754,
+ "src": "4386:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$__$",
+ "typeString": "modifier ()"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "4386:9:0"
+ },
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 129,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 120,
+ "src": "4426:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ ],
+ "id": 128,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "4418:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 127,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "4418:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 130,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "4418:15:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "id": 131,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 126,
+ "name": "validAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22618,
+ "src": "4405:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$_t_address_$",
+ "typeString": "modifier (address)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "4405:29:0"
+ },
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 135,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 120,
+ "src": "4460:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ ],
+ "id": 134,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "4452:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 133,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "4452:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 136,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "4452:15:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "id": 137,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 132,
+ "name": "notThis",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22644,
+ "src": "4444:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$_t_address_$",
+ "typeString": "modifier (address)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "4444:24:0"
+ }
+ ],
+ "name": "registerEtherToken",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 123,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 120,
+ "mutability": "mutable",
+ "name": "_token",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 146,
+ "src": "4325:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 119,
+ "name": "IEtherToken",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21153,
+ "src": "4325:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 122,
+ "mutability": "mutable",
+ "name": "_register",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 146,
+ "src": "4345:14:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 121,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "4345:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "4324:36:0"
+ },
+ "returnParameters": {
+ "id": 138,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "4474:0:0"
+ },
+ "scope": 1976,
+ "src": "4297:227:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 171,
+ "nodeType": "Block",
+ "src": "5021:175:0",
+ "statements": [
+ {
+ "assignments": [
+ 158
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 158,
+ "mutability": "mutable",
+ "name": "pathFinder",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 171,
+ "src": "5032:32:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConversionPathFinder_$2546",
+ "typeString": "contract IConversionPathFinder"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 157,
+ "name": "IConversionPathFinder",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 2546,
+ "src": "5032:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConversionPathFinder_$2546",
+ "typeString": "contract IConversionPathFinder"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 164,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 161,
+ "name": "CONVERSION_PATH_FINDER",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21539,
+ "src": "5099:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ ],
+ "id": 160,
+ "name": "addressOf",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21718,
+ "src": "5089:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$",
+ "typeString": "function (bytes32) view returns (address)"
+ }
+ },
+ "id": 162,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "5089:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 159,
+ "name": "IConversionPathFinder",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2546,
+ "src": "5067:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IConversionPathFinder_$2546_$",
+ "typeString": "type(contract IConversionPathFinder)"
+ }
+ },
+ "id": 163,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "5067:56:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConversionPathFinder_$2546",
+ "typeString": "contract IConversionPathFinder"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "5032:91:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 167,
+ "name": "_sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 149,
+ "src": "5161:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 168,
+ "name": "_targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 151,
+ "src": "5175:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 165,
+ "name": "pathFinder",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 158,
+ "src": "5141:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConversionPathFinder_$2546",
+ "typeString": "contract IConversionPathFinder"
+ }
+ },
+ "id": 166,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "findPath",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 2545,
+ "src": "5141:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_contract$_IERC20Token_$21127_$_t_contract$_IERC20Token_$21127_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
+ "typeString": "function (contract IERC20Token,contract IERC20Token) view external returns (address[] memory)"
+ }
+ },
+ "id": 169,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "5141:47:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "functionReturnParameters": 156,
+ "id": 170,
+ "nodeType": "Return",
+ "src": "5134:54:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 147,
+ "nodeType": "StructuredDocumentation",
+ "src": "4532:368:0",
+ "text": " @dev returns the conversion path between two tokens in the network\n note that this method is quite expensive in terms of gas and should generally be called off-chain\n @param _sourceToken source token address\n @param _targetToken target token address\n @return conversion path between the two tokens"
+ },
+ "functionSelector": "d734fa19",
+ "id": 172,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "conversionPath",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 152,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 149,
+ "mutability": "mutable",
+ "name": "_sourceToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 172,
+ "src": "4930:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 148,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "4930:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 151,
+ "mutability": "mutable",
+ "name": "_targetToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 172,
+ "src": "4956:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 150,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "4956:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "4929:52:0"
+ },
+ "returnParameters": {
+ "id": 156,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 155,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 172,
+ "src": "5003:16:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 153,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "5003:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 154,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "5003:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "5002:18:0"
+ },
+ "scope": 1976,
+ "src": "4906:290:0",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 461,
+ "nodeType": "Block",
+ "src": "5682:2762:0",
+ "statements": [
+ {
+ "assignments": [
+ 184
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 184,
+ "mutability": "mutable",
+ "name": "amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 461,
+ "src": "5693:14:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 183,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "5693:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 185,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "5693:14:0"
+ },
+ {
+ "assignments": [
+ 187
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 187,
+ "mutability": "mutable",
+ "name": "fee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 461,
+ "src": "5718:11:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 186,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "5718:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 188,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "5718:11:0"
+ },
+ {
+ "assignments": [
+ 190
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 190,
+ "mutability": "mutable",
+ "name": "supply",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 461,
+ "src": "5740:14:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 189,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "5740:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 191,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "5740:14:0"
+ },
+ {
+ "assignments": [
+ 193
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 193,
+ "mutability": "mutable",
+ "name": "balance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 461,
+ "src": "5765:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 192,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "5765:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 194,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "5765:15:0"
+ },
+ {
+ "assignments": [
+ 196
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 196,
+ "mutability": "mutable",
+ "name": "weight",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 461,
+ "src": "5791:13:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ "typeName": {
+ "id": 195,
+ "name": "uint32",
+ "nodeType": "ElementaryTypeName",
+ "src": "5791:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 197,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "5791:13:0"
+ },
+ {
+ "assignments": [
+ 199
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 199,
+ "mutability": "mutable",
+ "name": "converter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 461,
+ "src": "5815:20:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 198,
+ "name": "IConverter",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13340,
+ "src": "5815:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 200,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "5815:20:0"
+ },
+ {
+ "assignments": [
+ 202
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 202,
+ "mutability": "mutable",
+ "name": "formula",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 461,
+ "src": "5846:22:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorFormula_$13177",
+ "typeString": "contract IBancorFormula"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 201,
+ "name": "IBancorFormula",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13177,
+ "src": "5846:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorFormula_$13177",
+ "typeString": "contract IBancorFormula"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 208,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 205,
+ "name": "BANCOR_FORMULA",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21533,
+ "src": "5896:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ ],
+ "id": 204,
+ "name": "addressOf",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21718,
+ "src": "5886:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$",
+ "typeString": "function (bytes32) view returns (address)"
+ }
+ },
+ "id": 206,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "5886:25:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 203,
+ "name": "IBancorFormula",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 13177,
+ "src": "5871:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IBancorFormula_$13177_$",
+ "typeString": "type(contract IBancorFormula)"
+ }
+ },
+ "id": 207,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "5871:41:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorFormula_$13177",
+ "typeString": "contract IBancorFormula"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "5846:66:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 211,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 209,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "5925:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 210,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 178,
+ "src": "5934:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "5925:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 212,
+ "nodeType": "ExpressionStatement",
+ "src": "5925:16:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 224,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 217,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 214,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 176,
+ "src": "6034:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 215,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "6034:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 216,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6049:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "6034:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 223,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 221,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 218,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 176,
+ "src": "6054:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 219,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "6054:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "%",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 220,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6069:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "6054:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 222,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6074:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "6054:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "6034:41:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f50415448",
+ "id": 225,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6077:18:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_db637d0ca669449dd352e97481d5a38953b8126ef5f657bdd830d33ff33d5b16",
+ "typeString": "literal_string \"ERR_INVALID_PATH\""
+ },
+ "value": "ERR_INVALID_PATH"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_db637d0ca669449dd352e97481d5a38953b8126ef5f657bdd830d33ff33d5b16",
+ "typeString": "literal_string \"ERR_INVALID_PATH\""
+ }
+ ],
+ "id": 213,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "6026:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 226,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6026:70:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 227,
+ "nodeType": "ExpressionStatement",
+ "src": "6026:70:0"
+ },
+ {
+ "body": {
+ "id": 457,
+ "nodeType": "Block",
+ "src": "6200:2211:0",
+ "statements": [
+ {
+ "assignments": [
+ 241
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 241,
+ "mutability": "mutable",
+ "name": "sourceToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 457,
+ "src": "6215:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 240,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "6215:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 249,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 243,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 176,
+ "src": "6253:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 247,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 246,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 244,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "6259:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 245,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6263:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "6259:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "6253:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 242,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "6241:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 248,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6241:25:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "6215:51:0"
+ },
+ {
+ "assignments": [
+ 251
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 251,
+ "mutability": "mutable",
+ "name": "anchor",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 457,
+ "src": "6281:14:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 250,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "6281:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 257,
+ "initialValue": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 252,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 176,
+ "src": "6298:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 256,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 255,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 253,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "6304:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 254,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6308:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "6304:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "6298:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "6281:29:0"
+ },
+ {
+ "assignments": [
+ 259
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 259,
+ "mutability": "mutable",
+ "name": "targetToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 457,
+ "src": "6325:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 258,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "6325:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 265,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 261,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 176,
+ "src": "6363:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 263,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 262,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "6369:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "6363:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 260,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "6351:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 264,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6351:21:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "6325:47:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 277,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 266,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "6389:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 271,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 251,
+ "src": "6437:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 270,
+ "name": "IConverterAnchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 13349,
+ "src": "6420:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IConverterAnchor_$13349_$",
+ "typeString": "type(contract IConverterAnchor)"
+ }
+ },
+ "id": 272,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6420:24:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ "id": 273,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "owner",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22838,
+ "src": "6420:30:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_address_$",
+ "typeString": "function () view external returns (address)"
+ }
+ },
+ "id": 274,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6420:32:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 269,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "6412:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_payable_$",
+ "typeString": "type(address payable)"
+ },
+ "typeName": {
+ "id": 268,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "6412:8:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 275,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6412:41:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "id": 267,
+ "name": "IConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 13340,
+ "src": "6401:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IConverter_$13340_$",
+ "typeString": "type(contract IConverter)"
+ }
+ },
+ "id": 276,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6401:53:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "src": "6389:65:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 278,
+ "nodeType": "ExpressionStatement",
+ "src": "6389:65:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 284,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 279,
+ "name": "sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 241,
+ "src": "6510:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 281,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "6549:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 282,
+ "name": "sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 241,
+ "src": "6560:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "id": 280,
+ "name": "getConverterTokenAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1579,
+ "src": "6524:24:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$_t_contract$_IERC20Token_$21127_$returns$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "function (contract IConverter,contract IERC20Token) view returns (contract IERC20Token)"
+ }
+ },
+ "id": 283,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6524:48:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "6510:62:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "id": 285,
+ "nodeType": "ExpressionStatement",
+ "src": "6510:62:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 291,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 286,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 259,
+ "src": "6587:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 288,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "6626:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 289,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 259,
+ "src": "6637:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "id": 287,
+ "name": "getConverterTokenAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1579,
+ "src": "6601:24:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$_t_contract$_IERC20Token_$21127_$returns$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "function (contract IConverter,contract IERC20Token) view returns (contract IERC20Token)"
+ }
+ },
+ "id": 290,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6601:48:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "6587:62:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "id": 292,
+ "nodeType": "ExpressionStatement",
+ "src": "6587:62:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "id": 298,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 295,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 259,
+ "src": "6678:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "id": 294,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "6670:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 293,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "6670:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 296,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6670:20:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 297,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 251,
+ "src": "6694:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "src": "6670:30:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "id": 373,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 370,
+ "name": "sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 241,
+ "src": "7480:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "id": 369,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "7472:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 368,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "7472:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 371,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7472:20:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 372,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 251,
+ "src": "7496:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "src": "7472:30:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "id": 454,
+ "nodeType": "Block",
+ "src": "8267:133:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 452,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 443,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "8315:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 444,
+ "name": "fee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 187,
+ "src": "8323:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 445,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "8314:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 447,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "8340:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 448,
+ "name": "sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 241,
+ "src": "8351:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 449,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 259,
+ "src": "8364:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 450,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "8377:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 446,
+ "name": "getReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1664,
+ "src": "8330:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$_t_contract$_IERC20Token_$21127_$_t_contract$_IERC20Token_$21127_$_t_uint256_$returns$_t_uint256_$_t_uint256_$",
+ "typeString": "function (contract IConverter,contract IERC20Token,contract IERC20Token,uint256) view returns (uint256,uint256)"
+ }
+ },
+ "id": 451,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "8330:54:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "src": "8314:70:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 453,
+ "nodeType": "ExpressionStatement",
+ "src": "8314:70:0"
+ }
+ ]
+ },
+ "id": 455,
+ "nodeType": "IfStatement",
+ "src": "7468:932:0",
+ "trueBody": {
+ "id": 442,
+ "nodeType": "Block",
+ "src": "7504:744:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 384,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 376,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 374,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "7616:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "33",
+ "id": 375,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7620:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3_by_1",
+ "typeString": "int_const 3"
+ },
+ "value": "3"
+ },
+ "src": "7616:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "||",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "id": 383,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 377,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 251,
+ "src": "7625:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 378,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 176,
+ "src": "7635:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 382,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 381,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 379,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "7641:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "33",
+ "id": 380,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "7645:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3_by_1",
+ "typeString": "int_const 3"
+ },
+ "value": "3"
+ },
+ "src": "7641:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "7635:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "src": "7625:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "7616:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 393,
+ "nodeType": "IfStatement",
+ "src": "7612:100:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 391,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 385,
+ "name": "supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 190,
+ "src": "7670:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 387,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 251,
+ "src": "7691:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 386,
+ "name": "ISmartToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21182,
+ "src": "7679:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_ISmartToken_$21182_$",
+ "typeString": "type(contract ISmartToken)"
+ }
+ },
+ "id": 388,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7679:19:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_ISmartToken_$21182",
+ "typeString": "contract ISmartToken"
+ }
+ },
+ "id": 389,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "totalSupply",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 21081,
+ "src": "7679:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_uint256_$",
+ "typeString": "function () view external returns (uint256)"
+ }
+ },
+ "id": 390,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7679:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "7670:42:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 392,
+ "nodeType": "ExpressionStatement",
+ "src": "7670:42:0"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 399,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 394,
+ "name": "balance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 193,
+ "src": "7789:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 397,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 259,
+ "src": "7829:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 395,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "7799:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 396,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "getConnectorBalance",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13327,
+ "src": "7799:29:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_contract$_IERC20Token_$21127_$returns$_t_uint256_$",
+ "typeString": "function (contract IERC20Token) view external returns (uint256)"
+ }
+ },
+ "id": 398,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7799:42:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "7789:52:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 400,
+ "nodeType": "ExpressionStatement",
+ "src": "7789:52:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 407,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ null,
+ {
+ "argumentTypes": null,
+ "id": 401,
+ "name": "weight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 196,
+ "src": "7863:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ null,
+ null,
+ null
+ ],
+ "id": 402,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "7860:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$_t_uint32_$__$__$__$",
+ "typeString": "tuple(,uint32,,,)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 405,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 259,
+ "src": "7900:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 403,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "7879:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 404,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "connectors",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13320,
+ "src": "7879:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_contract$_IERC20Token_$21127_$returns$_t_uint256_$_t_uint32_$_t_bool_$_t_bool_$_t_bool_$",
+ "typeString": "function (contract IERC20Token) view external returns (uint256,uint32,bool,bool,bool)"
+ }
+ },
+ "id": 406,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7879:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint32_$_t_bool_$_t_bool_$_t_bool_$",
+ "typeString": "tuple(uint256,uint32,bool,bool,bool)"
+ }
+ },
+ "src": "7860:52:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 408,
+ "nodeType": "ExpressionStatement",
+ "src": "7860:52:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 417,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 409,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "7931:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 412,
+ "name": "supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 190,
+ "src": "7965:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 413,
+ "name": "balance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 193,
+ "src": "7973:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 414,
+ "name": "weight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 196,
+ "src": "7982:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 415,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "7990:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 410,
+ "name": "formula",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 202,
+ "src": "7940:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorFormula_$13177",
+ "typeString": "contract IBancorFormula"
+ }
+ },
+ "id": 411,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "saleTargetAmount",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13105,
+ "src": "7940:24:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view external returns (uint256)"
+ }
+ },
+ "id": 416,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7940:57:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "7931:66:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 418,
+ "nodeType": "ExpressionStatement",
+ "src": "7931:66:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 429,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 419,
+ "name": "fee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 187,
+ "src": "8016:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 427,
+ "name": "PPM_RESOLUTION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 39,
+ "src": "8064:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "id": 422,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "8033:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 423,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "conversionFee",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13238,
+ "src": "8033:23:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_uint32_$",
+ "typeString": "function () view external returns (uint32)"
+ }
+ },
+ "id": 424,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "8033:25:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 420,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "8022:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 421,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "8022:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 425,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "8022:37:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 426,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "div",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22353,
+ "src": "8022:41:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 428,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "8022:57:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "8016:63:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 430,
+ "nodeType": "ExpressionStatement",
+ "src": "8016:63:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 433,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 431,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "8098:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 432,
+ "name": "fee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 187,
+ "src": "8108:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "8098:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 434,
+ "nodeType": "ExpressionStatement",
+ "src": "8098:13:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 440,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 435,
+ "name": "supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 190,
+ "src": "8205:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 438,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "8225:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 436,
+ "name": "supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 190,
+ "src": "8214:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 437,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sub",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22293,
+ "src": "8214:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 439,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "8214:18:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "8205:27:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 441,
+ "nodeType": "ExpressionStatement",
+ "src": "8205:27:0"
+ }
+ ]
+ }
+ },
+ "id": 456,
+ "nodeType": "IfStatement",
+ "src": "6666:1734:0",
+ "trueBody": {
+ "id": 367,
+ "nodeType": "Block",
+ "src": "6702:747:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 309,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 301,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 299,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "6813:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "33",
+ "id": 300,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6817:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3_by_1",
+ "typeString": "int_const 3"
+ },
+ "value": "3"
+ },
+ "src": "6813:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "||",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "id": 308,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 302,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 251,
+ "src": "6822:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 303,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 176,
+ "src": "6832:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 307,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 306,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 304,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "6838:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "33",
+ "id": 305,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6842:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_3_by_1",
+ "typeString": "int_const 3"
+ },
+ "value": "3"
+ },
+ "src": "6838:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "6832:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "src": "6822:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "6813:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 318,
+ "nodeType": "IfStatement",
+ "src": "6809:100:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 316,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 310,
+ "name": "supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 190,
+ "src": "6867:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 312,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 251,
+ "src": "6888:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 311,
+ "name": "ISmartToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21182,
+ "src": "6876:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_ISmartToken_$21182_$",
+ "typeString": "type(contract ISmartToken)"
+ }
+ },
+ "id": 313,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6876:19:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_ISmartToken_$21182",
+ "typeString": "contract ISmartToken"
+ }
+ },
+ "id": 314,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "totalSupply",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 21081,
+ "src": "6876:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_uint256_$",
+ "typeString": "function () view external returns (uint256)"
+ }
+ },
+ "id": 315,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6876:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "6867:42:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 317,
+ "nodeType": "ExpressionStatement",
+ "src": "6867:42:0"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 324,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 319,
+ "name": "balance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 193,
+ "src": "6986:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 322,
+ "name": "sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 241,
+ "src": "7026:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 320,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "6996:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 321,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "getConnectorBalance",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13327,
+ "src": "6996:29:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_contract$_IERC20Token_$21127_$returns$_t_uint256_$",
+ "typeString": "function (contract IERC20Token) view external returns (uint256)"
+ }
+ },
+ "id": 323,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6996:42:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "6986:52:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 325,
+ "nodeType": "ExpressionStatement",
+ "src": "6986:52:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 332,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "components": [
+ null,
+ {
+ "argumentTypes": null,
+ "id": 326,
+ "name": "weight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 196,
+ "src": "7060:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ null,
+ null,
+ null
+ ],
+ "id": 327,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "TupleExpression",
+ "src": "7057:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$_t_uint32_$__$__$__$",
+ "typeString": "tuple(,uint32,,,)"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 330,
+ "name": "sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 241,
+ "src": "7097:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 328,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "7076:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 329,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "connectors",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13320,
+ "src": "7076:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_contract$_IERC20Token_$21127_$returns$_t_uint256_$_t_uint32_$_t_bool_$_t_bool_$_t_bool_$",
+ "typeString": "function (contract IERC20Token) view external returns (uint256,uint32,bool,bool,bool)"
+ }
+ },
+ "id": 331,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7076:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint32_$_t_bool_$_t_bool_$_t_bool_$",
+ "typeString": "tuple(uint256,uint32,bool,bool,bool)"
+ }
+ },
+ "src": "7057:52:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 333,
+ "nodeType": "ExpressionStatement",
+ "src": "7057:52:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 342,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 334,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "7128:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 337,
+ "name": "supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 190,
+ "src": "7166:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 338,
+ "name": "balance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 193,
+ "src": "7174:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 339,
+ "name": "weight",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 196,
+ "src": "7183:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 340,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "7191:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 335,
+ "name": "formula",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 202,
+ "src": "7137:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorFormula_$13177",
+ "typeString": "contract IBancorFormula"
+ }
+ },
+ "id": 336,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "purchaseTargetAmount",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13092,
+ "src": "7137:28:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_uint256_$_t_uint256_$_t_uint32_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (uint256,uint256,uint32,uint256) view external returns (uint256)"
+ }
+ },
+ "id": 341,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7137:61:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "7128:70:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 343,
+ "nodeType": "ExpressionStatement",
+ "src": "7128:70:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 354,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 344,
+ "name": "fee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 187,
+ "src": "7217:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 352,
+ "name": "PPM_RESOLUTION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 39,
+ "src": "7265:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "id": 347,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 199,
+ "src": "7234:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 348,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "conversionFee",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13238,
+ "src": "7234:23:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_uint32_$",
+ "typeString": "function () view external returns (uint32)"
+ }
+ },
+ "id": 349,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7234:25:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint32",
+ "typeString": "uint32"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 345,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "7223:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 346,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "7223:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 350,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7223:37:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 351,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "div",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22353,
+ "src": "7223:41:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 353,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7223:57:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "7217:63:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 355,
+ "nodeType": "ExpressionStatement",
+ "src": "7217:63:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 358,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 356,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "7299:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 357,
+ "name": "fee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 187,
+ "src": "7309:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "7299:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 359,
+ "nodeType": "ExpressionStatement",
+ "src": "7299:13:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 365,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 360,
+ "name": "supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 190,
+ "src": "7406:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 363,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "7426:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 361,
+ "name": "supply",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 190,
+ "src": "7415:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 362,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "add",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22271,
+ "src": "7415:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 364,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "7415:18:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "7406:27:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 366,
+ "nodeType": "ExpressionStatement",
+ "src": "7406:27:0"
+ }
+ ]
+ }
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 235,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 232,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "6174:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 233,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 176,
+ "src": "6178:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 234,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "6178:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "6174:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 458,
+ "initializationExpression": {
+ "assignments": [
+ 229
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 229,
+ "mutability": "mutable",
+ "name": "i",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 458,
+ "src": "6159:9:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 228,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "6159:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 231,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 230,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6171:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "6159:13:0"
+ },
+ "loopExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 238,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 236,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 229,
+ "src": "6192:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 237,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6197:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "6192:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 239,
+ "nodeType": "ExpressionStatement",
+ "src": "6192:6:0"
+ },
+ "nodeType": "ForStatement",
+ "src": "6154:2257:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 459,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 184,
+ "src": "8430:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 182,
+ "id": 460,
+ "nodeType": "Return",
+ "src": "8423:13:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 173,
+ "nodeType": "StructuredDocumentation",
+ "src": "5204:381:0",
+ "text": " @dev returns the expected target amount of converting a given amount on a given path\n note that there is no support for circular paths\n @param _path conversion path (see conversion path format above)\n @param _amount amount of _path[0] tokens received from the sender\n @return expected target amount"
+ },
+ "functionSelector": "7f9c0ecd",
+ "id": 462,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "rateByPath",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 179,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 176,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 462,
+ "src": "5611:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 174,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "5611:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 175,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "5611:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 178,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 462,
+ "src": "5635:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 177,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "5635:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "5610:41:0"
+ },
+ "returnParameters": {
+ "id": 182,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 181,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 462,
+ "src": "5673:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 180,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "5673:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "5672:9:0"
+ },
+ "scope": 1976,
+ "src": "5591:2853:0",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 597,
+ "nodeType": "Block",
+ "src": "9948:1329:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 497,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 490,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 487,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 466,
+ "src": "10073:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 488,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "10073:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 489,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10088:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "10073:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 496,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 494,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 491,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 466,
+ "src": "10093:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 492,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "10093:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "%",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 493,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10108:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "10093:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 495,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10113:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "10093:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "10073:41:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f50415448",
+ "id": 498,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10116:18:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_db637d0ca669449dd352e97481d5a38953b8126ef5f657bdd830d33ff33d5b16",
+ "typeString": "literal_string \"ERR_INVALID_PATH\""
+ },
+ "value": "ERR_INVALID_PATH"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_db637d0ca669449dd352e97481d5a38953b8126ef5f657bdd830d33ff33d5b16",
+ "typeString": "literal_string \"ERR_INVALID_PATH\""
+ }
+ ],
+ "id": 486,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "10065:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 499,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10065:70:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 500,
+ "nodeType": "ExpressionStatement",
+ "src": "10065:70:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 503,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 466,
+ "src": "10257:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 505,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 504,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10263:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "10257:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 502,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "10245:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 506,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10245:21:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 508,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 466,
+ "src": "10285:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 510,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 509,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10291:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "10285:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 507,
+ "name": "IConverterAnchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 13349,
+ "src": "10268:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IConverterAnchor_$13349_$",
+ "typeString": "type(contract IConverterAnchor)"
+ }
+ },
+ "id": 511,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10268:26:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 512,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 468,
+ "src": "10296:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 501,
+ "name": "handleSourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1110,
+ "src": "10227:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_contract$_IConverterAnchor_$13349_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,contract IConverterAnchor,uint256)"
+ }
+ },
+ "id": 513,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10227:77:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 514,
+ "nodeType": "ExpressionStatement",
+ "src": "10227:77:0"
+ },
+ {
+ "assignments": [
+ 516
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 516,
+ "mutability": "mutable",
+ "name": "affiliateFeeEnabled",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 597,
+ "src": "10363:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 515,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "10363:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 518,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "66616c7365",
+ "id": 517,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10390:5:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "false"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "10363:32:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "id": 527,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 521,
+ "name": "_affiliateAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 474,
+ "src": "10418:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 520,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "10410:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 519,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "10410:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 522,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10410:26:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 525,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10448:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 524,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "10440:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 523,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "10440:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 526,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10440:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "src": "10410:40:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "id": 551,
+ "nodeType": "Block",
+ "src": "10550:159:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 543,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 539,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 537,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10573:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 538,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 476,
+ "src": "10577:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "10573:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 542,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 540,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 476,
+ "src": "10594:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 541,
+ "name": "maxAffiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 62,
+ "src": "10611:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "10594:32:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "10573:53:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f414646494c494154455f464545",
+ "id": 544,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10628:27:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_5421a6ae0116cbc310697cd7899b77d6a7bc1fb10cd896c84c63fd20f8fbd382",
+ "typeString": "literal_string \"ERR_INVALID_AFFILIATE_FEE\""
+ },
+ "value": "ERR_INVALID_AFFILIATE_FEE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_5421a6ae0116cbc310697cd7899b77d6a7bc1fb10cd896c84c63fd20f8fbd382",
+ "typeString": "literal_string \"ERR_INVALID_AFFILIATE_FEE\""
+ }
+ ],
+ "id": 536,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "10565:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 545,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10565:91:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 546,
+ "nodeType": "ExpressionStatement",
+ "src": "10565:91:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 549,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 547,
+ "name": "affiliateFeeEnabled",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 516,
+ "src": "10671:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "74727565",
+ "id": 548,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10693:4:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "true"
+ },
+ "src": "10671:26:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 550,
+ "nodeType": "ExpressionStatement",
+ "src": "10671:26:0"
+ }
+ ]
+ },
+ "id": 552,
+ "nodeType": "IfStatement",
+ "src": "10406:303:0",
+ "trueBody": {
+ "id": 535,
+ "nodeType": "Block",
+ "src": "10452:83:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 531,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 529,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 476,
+ "src": "10475:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 530,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10492:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "10475:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f414646494c494154455f464545",
+ "id": 532,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10495:27:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_5421a6ae0116cbc310697cd7899b77d6a7bc1fb10cd896c84c63fd20f8fbd382",
+ "typeString": "literal_string \"ERR_INVALID_AFFILIATE_FEE\""
+ },
+ "value": "ERR_INVALID_AFFILIATE_FEE"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_5421a6ae0116cbc310697cd7899b77d6a7bc1fb10cd896c84c63fd20f8fbd382",
+ "typeString": "literal_string \"ERR_INVALID_AFFILIATE_FEE\""
+ }
+ ],
+ "id": 528,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "10467:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 533,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10467:56:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 534,
+ "nodeType": "ExpressionStatement",
+ "src": "10467:56:0"
+ }
+ ]
+ }
+ },
+ {
+ "assignments": [
+ 554
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 554,
+ "mutability": "mutable",
+ "name": "beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 597,
+ "src": "10761:27:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 553,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "10761:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 557,
+ "initialValue": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 555,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "10791:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 556,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sender",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "10791:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "10761:40:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "id": 563,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 558,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 472,
+ "src": "10816:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 561,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "10840:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 560,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "10832:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 559,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "10832:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 562,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10832:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "src": "10816:26:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 568,
+ "nodeType": "IfStatement",
+ "src": "10812:71:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 566,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 564,
+ "name": "beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 554,
+ "src": "10857:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 565,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 472,
+ "src": "10871:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "src": "10857:26:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "id": 567,
+ "nodeType": "ExpressionStatement",
+ "src": "10857:26:0"
+ }
+ },
+ {
+ "assignments": [
+ 572
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 572,
+ "mutability": "mutable",
+ "name": "data",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 597,
+ "src": "10945:28:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ },
+ "typeName": {
+ "baseType": {
+ "contractScope": null,
+ "id": 570,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "10945:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "id": 571,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "10945:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_storage_$dyn_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 578,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 574,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 466,
+ "src": "10997:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 575,
+ "name": "beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 554,
+ "src": "11004:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 576,
+ "name": "affiliateFeeEnabled",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 516,
+ "src": "11017:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ ],
+ "id": 573,
+ "name": "createConversionData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1468,
+ "src": "10976:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_array$_t_address_$dyn_memory_ptr_$_t_address_payable_$_t_bool_$returns$_t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr_$",
+ "typeString": "function (address[] memory,address payable,bool) view returns (struct BancorNetwork.ConversionStep memory[] memory)"
+ }
+ },
+ "id": 577,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "10976:61:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "10945:92:0"
+ },
+ {
+ "assignments": [
+ 580
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 580,
+ "mutability": "mutable",
+ "name": "amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 597,
+ "src": "11048:14:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 579,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "11048:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 588,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 582,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 572,
+ "src": "11078:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 583,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 468,
+ "src": "11084:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 584,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 470,
+ "src": "11093:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 585,
+ "name": "_affiliateAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 474,
+ "src": "11105:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 586,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 476,
+ "src": "11124:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 581,
+ "name": "doConversion",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 998,
+ "src": "11065:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (struct BancorNetwork.ConversionStep memory[] memory,uint256,uint256,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 587,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "11065:73:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "11048:90:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 590,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 572,
+ "src": "11217:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 591,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 580,
+ "src": "11223:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 592,
+ "name": "beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 554,
+ "src": "11231:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "id": 589,
+ "name": "handleTargetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1174,
+ "src": "11199:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr_$_t_uint256_$_t_address_payable_$returns$__$",
+ "typeString": "function (struct BancorNetwork.ConversionStep memory[] memory,uint256,address payable)"
+ }
+ },
+ "id": 593,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "11199:44:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 594,
+ "nodeType": "ExpressionStatement",
+ "src": "11199:44:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 595,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 580,
+ "src": "11263:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 485,
+ "id": 596,
+ "nodeType": "Return",
+ "src": "11256:13:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 463,
+ "nodeType": "StructuredDocumentation",
+ "src": "8452:1150:0",
+ "text": " @dev converts the token to any other token in the bancor network by following\n a predefined conversion path and transfers the result tokens to a target account\n affiliate account/fee can also be passed in to receive a conversion fee (on top of the liquidity provider fees)\n note that the network should already have been given allowance of the source token (if not ETH)\n @param _path conversion path, see conversion path format above\n @param _amount amount to convert from, in the source token\n @param _minReturn if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero\n @param _beneficiary account that will receive the conversion result or 0x0 to send the result to the sender account\n @param _affiliateAccount wallet address to receive the affiliate fee or 0x0 to disable affiliate fee\n @param _affiliateFee affiliate fee in PPM or 0 to disable affiliate fee\n @return amount of tokens received from the conversion"
+ },
+ "functionSelector": "b77d239b",
+ "id": 598,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [
+ {
+ "arguments": null,
+ "id": 479,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 478,
+ "name": "protected",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22231,
+ "src": "9869:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$__$",
+ "typeString": "modifier ()"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "9869:9:0"
+ },
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 481,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 470,
+ "src": "9904:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 482,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 480,
+ "name": "greaterThanZero",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22595,
+ "src": "9888:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$_t_uint256_$",
+ "typeString": "modifier (uint256)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "9888:27:0"
+ }
+ ],
+ "name": "convertByPath",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 477,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 466,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 598,
+ "src": "9641:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 464,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "9641:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 465,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "9641:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 468,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 598,
+ "src": "9674:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 467,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "9674:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 470,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 598,
+ "src": "9700:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 469,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "9700:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 472,
+ "mutability": "mutable",
+ "name": "_beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 598,
+ "src": "9729:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 471,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "9729:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 474,
+ "mutability": "mutable",
+ "name": "_affiliateAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 598,
+ "src": "9768:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 473,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "9768:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 476,
+ "mutability": "mutable",
+ "name": "_affiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 598,
+ "src": "9804:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 475,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "9804:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "9630:196:0"
+ },
+ "returnParameters": {
+ "id": 485,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 484,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 598,
+ "src": "9934:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 483,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "9934:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "9933:9:0"
+ },
+ "scope": 1976,
+ "src": "9608:1669:0",
+ "stateMutability": "payable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 631,
+ "nodeType": "Block",
+ "src": "12548:128:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 618,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 602,
+ "src": "12576:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 619,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 604,
+ "src": "12583:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 620,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 606,
+ "src": "12592:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 621,
+ "name": "_targetBlockchain",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 608,
+ "src": "12604:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 622,
+ "name": "_targetAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 610,
+ "src": "12623:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 623,
+ "name": "_conversionId",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 612,
+ "src": "12639:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 626,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12662:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 625,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "12654:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 624,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "12654:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 627,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "12654:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 628,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "12666:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 617,
+ "name": "xConvert2",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 726,
+ "src": "12566:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_bytes32_$_t_bytes32_$_t_uint256_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,bytes32,bytes32,uint256,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 629,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "12566:102:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 616,
+ "id": 630,
+ "nodeType": "Return",
+ "src": "12559:109:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 599,
+ "nodeType": "StructuredDocumentation",
+ "src": "11285:978:0",
+ "text": " @dev converts any other token to BNT in the bancor network by following\na predefined conversion path and transfers the result to an account on a different blockchain\n note that the network should already have been given allowance of the source token (if not ETH)\n @param _path conversion path, see conversion path format above\n @param _amount amount to convert from, in the source token\n @param _minReturn if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero\n @param _targetBlockchain blockchain BNT will be issued on\n @param _targetAccount address/account on the target blockchain to send the BNT to\n @param _conversionId pre-determined unique (if non zero) id which refers to this transaction\n @return the amount of BNT received from this conversion"
+ },
+ "functionSelector": "c52173de",
+ "id": 632,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "xConvert",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 613,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 602,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 632,
+ "src": "12297:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 600,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "12297:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 601,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "12297:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 604,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 632,
+ "src": "12330:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 603,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "12330:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 606,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 632,
+ "src": "12356:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 605,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "12356:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 608,
+ "mutability": "mutable",
+ "name": "_targetBlockchain",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 632,
+ "src": "12385:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ "typeName": {
+ "id": 607,
+ "name": "bytes32",
+ "nodeType": "ElementaryTypeName",
+ "src": "12385:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 610,
+ "mutability": "mutable",
+ "name": "_targetAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 632,
+ "src": "12421:22:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ "typeName": {
+ "id": 609,
+ "name": "bytes32",
+ "nodeType": "ElementaryTypeName",
+ "src": "12421:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 612,
+ "mutability": "mutable",
+ "name": "_conversionId",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 632,
+ "src": "12454:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 611,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "12454:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "12286:196:0"
+ },
+ "returnParameters": {
+ "id": 616,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 615,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 632,
+ "src": "12534:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 614,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "12534:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "12533:9:0"
+ },
+ "scope": 1976,
+ "src": "12269:407:0",
+ "stateMutability": "payable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 725,
+ "nodeType": "Block",
+ "src": "14166:739:0",
+ "statements": [
+ {
+ "assignments": [
+ 659
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 659,
+ "mutability": "mutable",
+ "name": "targetToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 725,
+ "src": "14177:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 658,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "14177:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 668,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 661,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 636,
+ "src": "14215:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 666,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 665,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 662,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 636,
+ "src": "14221:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 663,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "14221:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 664,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14236:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "14221:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "14215:23:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 660,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "14203:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 667,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14203:36:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "14177:62:0"
+ },
+ {
+ "assignments": [
+ 670
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 670,
+ "mutability": "mutable",
+ "name": "bancorX",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 725,
+ "src": "14250:16:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 669,
+ "name": "IBancorX",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 3551,
+ "src": "14250:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 676,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 673,
+ "name": "BANCOR_X",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21554,
+ "src": "14288:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ ],
+ "id": 672,
+ "name": "addressOf",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21718,
+ "src": "14278:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$",
+ "typeString": "function (bytes32) view returns (address)"
+ }
+ },
+ "id": 674,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14278:19:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 671,
+ "name": "IBancorX",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 3551,
+ "src": "14269:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IBancorX_$3551_$",
+ "typeString": "type(contract IBancorX)"
+ }
+ },
+ "id": 675,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14269:29:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "14250:48:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "id": 684,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 678,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 659,
+ "src": "14372:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 681,
+ "name": "BNT_TOKEN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21551,
+ "src": "14409:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ ],
+ "id": 680,
+ "name": "addressOf",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21718,
+ "src": "14399:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$",
+ "typeString": "function (bytes32) view returns (address)"
+ }
+ },
+ "id": 682,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14399:20:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 679,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "14387:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 683,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14387:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "14372:48:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f5441524745545f544f4b454e",
+ "id": 685,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "14422:26:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_506dba30f9da1ed4da3626f556faadafab0575131908ae8223c813a59e0707f3",
+ "typeString": "literal_string \"ERR_INVALID_TARGET_TOKEN\""
+ },
+ "value": "ERR_INVALID_TARGET_TOKEN"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_506dba30f9da1ed4da3626f556faadafab0575131908ae8223c813a59e0707f3",
+ "typeString": "literal_string \"ERR_INVALID_TARGET_TOKEN\""
+ }
+ ],
+ "id": 677,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "14364:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 686,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14364:85:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 687,
+ "nodeType": "ExpressionStatement",
+ "src": "14364:85:0"
+ },
+ {
+ "assignments": [
+ 689
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 689,
+ "mutability": "mutable",
+ "name": "amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 725,
+ "src": "14511:14:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 688,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "14511:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 704,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 691,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 636,
+ "src": "14542:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 692,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 638,
+ "src": "14549:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 693,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 640,
+ "src": "14558:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 698,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "14586:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 697,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "14578:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 696,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "14578:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 699,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14578:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 695,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "14570:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_payable_$",
+ "typeString": "type(address payable)"
+ },
+ "typeName": {
+ "id": 694,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "14570:8:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 700,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14570:22:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 701,
+ "name": "_affiliateAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 648,
+ "src": "14594:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 702,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 650,
+ "src": "14613:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 690,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "14528:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 703,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14528:99:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "14511:116:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 706,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 659,
+ "src": "14692:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 709,
+ "name": "bancorX",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 670,
+ "src": "14713:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ }
+ ],
+ "id": 708,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "14705:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 707,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "14705:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 710,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14705:16:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 711,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 689,
+ "src": "14723:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 705,
+ "name": "ensureAllowance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1511,
+ "src": "14676:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,uint256)"
+ }
+ },
+ "id": 712,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14676:54:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 713,
+ "nodeType": "ExpressionStatement",
+ "src": "14676:54:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 717,
+ "name": "_targetBlockchain",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 642,
+ "src": "14814:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 718,
+ "name": "_targetAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 644,
+ "src": "14833:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 719,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 689,
+ "src": "14849:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 720,
+ "name": "_conversionId",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 646,
+ "src": "14857:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 714,
+ "name": "bancorX",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 670,
+ "src": "14796:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ }
+ },
+ "id": 716,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "xTransfer",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 3541,
+ "src": "14796:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_nonpayable$_t_bytes32_$_t_bytes32_$_t_uint256_$_t_uint256_$returns$__$",
+ "typeString": "function (bytes32,bytes32,uint256,uint256) external"
+ }
+ },
+ "id": 721,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "14796:75:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 722,
+ "nodeType": "ExpressionStatement",
+ "src": "14796:75:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 723,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 689,
+ "src": "14891:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 657,
+ "id": 724,
+ "nodeType": "Return",
+ "src": "14884:13:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 633,
+ "nodeType": "StructuredDocumentation",
+ "src": "12684:1091:0",
+ "text": " @dev converts any other token to BNT in the bancor network by following\na predefined conversion path and transfers the result to an account on a different blockchain\n note that the network should already have been given allowance of the source token (if not ETH)\n @param _path conversion path, see conversion path format above\n @param _amount amount to convert from, in the source token\n @param _minReturn if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero\n @param _targetBlockchain blockchain BNT will be issued on\n @param _targetAccount address/account on the target blockchain to send the BNT to\n @param _conversionId pre-determined unique (if non zero) id which refers to this transaction\n @param _affiliateAccount affiliate account\n @param _affiliateFee affiliate fee in PPM\n @return the amount of BNT received from this conversion"
+ },
+ "functionSelector": "cb32564e",
+ "id": 726,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 653,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 640,
+ "src": "14122:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 654,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 652,
+ "name": "greaterThanZero",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22595,
+ "src": "14106:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$_t_uint256_$",
+ "typeString": "modifier (uint256)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "14106:27:0"
+ }
+ ],
+ "name": "xConvert2",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 651,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 636,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "13810:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 634,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "13810:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 635,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "13810:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 638,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "13843:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 637,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "13843:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 640,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "13869:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 639,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "13869:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 642,
+ "mutability": "mutable",
+ "name": "_targetBlockchain",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "13898:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ "typeName": {
+ "id": 641,
+ "name": "bytes32",
+ "nodeType": "ElementaryTypeName",
+ "src": "13898:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 644,
+ "mutability": "mutable",
+ "name": "_targetAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "13934:22:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ "typeName": {
+ "id": 643,
+ "name": "bytes32",
+ "nodeType": "ElementaryTypeName",
+ "src": "13934:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 646,
+ "mutability": "mutable",
+ "name": "_conversionId",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "13967:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 645,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "13967:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 648,
+ "mutability": "mutable",
+ "name": "_affiliateAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "13999:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 647,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "13999:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 650,
+ "mutability": "mutable",
+ "name": "_affiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "14035:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 649,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "14035:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "13799:264:0"
+ },
+ "returnParameters": {
+ "id": 657,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 656,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 726,
+ "src": "14152:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 655,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "14152:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "14151:9:0"
+ },
+ "scope": 1976,
+ "src": "13781:1124:0",
+ "stateMutability": "payable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 777,
+ "nodeType": "Block",
+ "src": "16040:423:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "id": 752,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 745,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 730,
+ "src": "16133:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 747,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 746,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16139:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "16133:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 744,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "16121:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 748,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "16121:21:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "id": 749,
+ "name": "_bancorX",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 732,
+ "src": "16146:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ }
+ },
+ "id": 750,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "token",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 3530,
+ "src": "16146:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "function () view external returns (contract IERC20Token)"
+ }
+ },
+ "id": 751,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "16146:16:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "16121:41:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f534f555243455f544f4b454e",
+ "id": 753,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16164:26:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_0f690a2bdb8b25e0198ca38056ef0e9f045e379ec977ffdcb1486f3c53b6e8fa",
+ "typeString": "literal_string \"ERR_INVALID_SOURCE_TOKEN\""
+ },
+ "value": "ERR_INVALID_SOURCE_TOKEN"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_0f690a2bdb8b25e0198ca38056ef0e9f045e379ec977ffdcb1486f3c53b6e8fa",
+ "typeString": "literal_string \"ERR_INVALID_SOURCE_TOKEN\""
+ }
+ ],
+ "id": 743,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "16113:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 754,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "16113:78:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 755,
+ "nodeType": "ExpressionStatement",
+ "src": "16113:78:0"
+ },
+ {
+ "assignments": [
+ 757
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 757,
+ "mutability": "mutable",
+ "name": "amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 777,
+ "src": "16260:14:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 756,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "16260:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 764,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 760,
+ "name": "_conversionId",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 734,
+ "src": "16305:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 761,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "16320:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 762,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sender",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "16320:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 758,
+ "name": "_bancorX",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 732,
+ "src": "16277:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ }
+ },
+ "id": 759,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "getXTransferAmount",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 3550,
+ "src": "16277:27:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_uint256_$_t_address_$returns$_t_uint256_$",
+ "typeString": "function (uint256,address) view external returns (uint256)"
+ }
+ },
+ "id": 763,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "16277:54:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "16260:71:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 766,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 730,
+ "src": "16400:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 767,
+ "name": "amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 757,
+ "src": "16407:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 768,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 736,
+ "src": "16415:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 769,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 738,
+ "src": "16427:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 772,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16449:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 771,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "16441:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 770,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "16441:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 773,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "16441:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 774,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "16453:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 765,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "16386:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 775,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "16386:69:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 742,
+ "id": 776,
+ "nodeType": "Return",
+ "src": "16379:76:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 727,
+ "nodeType": "StructuredDocumentation",
+ "src": "14913:937:0",
+ "text": " @dev allows a user to convert a token that was sent from another blockchain into any other\n token on the BancorNetwork\n ideally this transaction is created before the previous conversion is even complete, so\n so the input amount isn't known at that point - the amount is actually take from the\n BancorX contract directly by specifying the conversion id\n @param _path conversion path\n @param _bancorX address of the BancorX contract for the source token\n @param _conversionId pre-determined unique (if non zero) id which refers to this conversion\n @param _minReturn if the conversion results in an amount smaller than the minimum return - it is cancelled, must be nonzero\n @param _beneficiary wallet to receive the conversion result\n @return amount of tokens received from the conversion"
+ },
+ "functionSelector": "89f9cc61",
+ "id": 778,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "completeXConversion",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 739,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 730,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 778,
+ "src": "15885:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 728,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "15885:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 729,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "15885:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 732,
+ "mutability": "mutable",
+ "name": "_bancorX",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 778,
+ "src": "15909:17:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 731,
+ "name": "IBancorX",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 3551,
+ "src": "15909:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 734,
+ "mutability": "mutable",
+ "name": "_conversionId",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 778,
+ "src": "15928:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 733,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "15928:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 736,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 778,
+ "src": "15951:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 735,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "15951:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 738,
+ "mutability": "mutable",
+ "name": "_beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 778,
+ "src": "15971:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 737,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "15971:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "15884:116:0"
+ },
+ "returnParameters": {
+ "id": 742,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 741,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 778,
+ "src": "16026:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 740,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "16026:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "16025:9:0"
+ },
+ "scope": 1976,
+ "src": "15856:607:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 997,
+ "nodeType": "Block",
+ "src": "17298:2483:0",
+ "statements": [
+ {
+ "assignments": [
+ 796
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 796,
+ "mutability": "mutable",
+ "name": "toAmount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 997,
+ "src": "17309:16:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 795,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "17309:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 797,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "17309:16:0"
+ },
+ {
+ "assignments": [
+ 799
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 799,
+ "mutability": "mutable",
+ "name": "fromAmount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 997,
+ "src": "17336:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 798,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "17336:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 801,
+ "initialValue": {
+ "argumentTypes": null,
+ "id": 800,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 784,
+ "src": "17357:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "17336:28:0"
+ },
+ {
+ "body": {
+ "id": 986,
+ "nodeType": "Block",
+ "src": "17465:2151:0",
+ "statements": [
+ {
+ "assignments": [
+ 814
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 814,
+ "mutability": "mutable",
+ "name": "stepData",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 986,
+ "src": "17480:30:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 813,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "17480:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 818,
+ "initialValue": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 815,
+ "name": "_data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 782,
+ "src": "17513:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 817,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 816,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 803,
+ "src": "17519:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "17513:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "17480:41:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 819,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "17574:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 820,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "isV28OrHigherConverter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 56,
+ "src": "17574:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "id": 864,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 855,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18191:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 856,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "18191:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 860,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18235:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 861,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "anchor",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 48,
+ "src": "18235:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ ],
+ "id": 859,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "18227:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 858,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "18227:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 862,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18227:24:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 857,
+ "name": "ISmartToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21182,
+ "src": "18215:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_ISmartToken_$21182_$",
+ "typeString": "type(contract ISmartToken)"
+ }
+ },
+ "id": 863,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18215:37:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_ISmartToken_$21182",
+ "typeString": "contract ISmartToken"
+ }
+ },
+ "src": "18191:61:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 877,
+ "nodeType": "IfStatement",
+ "src": "18187:272:0",
+ "trueBody": {
+ "id": 876,
+ "nodeType": "Block",
+ "src": "18254:205:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 866,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18381:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 867,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "18381:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 870,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18411:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 871,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "converter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 46,
+ "src": "18411:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 869,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "18403:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 868,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "18403:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 872,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18403:27:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 873,
+ "name": "fromAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 799,
+ "src": "18432:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 865,
+ "name": "ensureAllowance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1511,
+ "src": "18365:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,uint256)"
+ }
+ },
+ "id": 874,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18365:78:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 875,
+ "nodeType": "ExpressionStatement",
+ "src": "18365:78:0"
+ }
+ ]
+ }
+ },
+ "id": 878,
+ "nodeType": "IfStatement",
+ "src": "17570:889:0",
+ "trueBody": {
+ "id": 854,
+ "nodeType": "Block",
+ "src": "17607:416:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 841,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 835,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 823,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 821,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 803,
+ "src": "17820:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 822,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17825:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "17820:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "id": 834,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 824,
+ "name": "_data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 782,
+ "src": "17830:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 828,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 827,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 825,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 803,
+ "src": "17836:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 826,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17840:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "17836:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "17830:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 829,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "17830:24:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 832,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "17866:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 831,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "17858:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 830,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "17858:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 833,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "17858:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "src": "17830:41:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "17820:51:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 840,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "!",
+ "prefix": true,
+ "src": "17875:34:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 836,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "17876:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 839,
+ "indexExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 837,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "17888:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 838,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "17888:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "17876:33:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "17820:89:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 853,
+ "nodeType": "IfStatement",
+ "src": "17816:191:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 843,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "17945:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 844,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "17945:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 847,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "17975:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 848,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "converter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 46,
+ "src": "17975:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 846,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "17967:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 845,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "17967:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 849,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "17967:27:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 850,
+ "name": "fromAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 799,
+ "src": "17996:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 842,
+ "name": "safeTransfer",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22475,
+ "src": "17932:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,uint256)"
+ }
+ },
+ "id": 851,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "17932:75:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 852,
+ "nodeType": "ExpressionStatement",
+ "src": "17932:75:0"
+ }
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "id": 881,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "!",
+ "prefix": true,
+ "src": "18513:32:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 879,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18514:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 880,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "isV28OrHigherConverter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 56,
+ "src": "18514:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "condition": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 900,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "18710:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 903,
+ "indexExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 901,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18722:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 902,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "18722:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "18710:33:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 937,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 923,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "18946:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 927,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18984:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 928,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "18984:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 929,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "19006:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 930,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "19006:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 931,
+ "name": "fromAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 799,
+ "src": "19028:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 932,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "19040:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 933,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sender",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "19040:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 934,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "19052:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 935,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "19052:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 924,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18957:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 925,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "converter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 46,
+ "src": "18957:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 926,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "convert",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13228,
+ "src": "18957:26:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_payable$_t_contract$_IERC20Token_$21127_$_t_contract$_IERC20Token_$21127_$_t_uint256_$_t_address_$_t_address_payable_$returns$_t_uint256_$",
+ "typeString": "function (contract IERC20Token,contract IERC20Token,uint256,address,address payable) payable external returns (uint256)"
+ }
+ },
+ "id": 936,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18957:116:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "18946:127:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 938,
+ "nodeType": "ExpressionStatement",
+ "src": "18946:127:0"
+ },
+ "id": 939,
+ "nodeType": "IfStatement",
+ "src": "18706:367:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 921,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 904,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "18762:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 911,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18820:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 912,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "18820:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 913,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18842:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 914,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "18842:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 915,
+ "name": "fromAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 799,
+ "src": "18864:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 916,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "18876:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 917,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sender",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "18876:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 918,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18888:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 919,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "18888:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 905,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18773:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 906,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "converter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 46,
+ "src": "18773:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 907,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "convert",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13228,
+ "src": "18773:26:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_payable$_t_contract$_IERC20Token_$21127_$_t_contract$_IERC20Token_$21127_$_t_uint256_$_t_address_$_t_address_payable_$returns$_t_uint256_$",
+ "typeString": "function (contract IERC20Token,contract IERC20Token,uint256,address,address payable) payable external returns (uint256)"
+ }
+ },
+ "id": 910,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "names": [
+ "value"
+ ],
+ "nodeType": "FunctionCallOptions",
+ "options": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 908,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "18808:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 909,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "value",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "18808:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "src": "18773:46:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_payable$_t_contract$_IERC20Token_$21127_$_t_contract$_IERC20Token_$21127_$_t_uint256_$_t_address_$_t_address_payable_$returns$_t_uint256_$value",
+ "typeString": "function (contract IERC20Token,contract IERC20Token,uint256,address,address payable) payable external returns (uint256)"
+ }
+ },
+ "id": 920,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18773:136:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "18762:147:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 922,
+ "nodeType": "ExpressionStatement",
+ "src": "18762:147:0"
+ }
+ },
+ "id": 940,
+ "nodeType": "IfStatement",
+ "src": "18509:564:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 898,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 882,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "18564:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 891,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18628:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 892,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "18628:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 893,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18650:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 894,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "18650:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 895,
+ "name": "fromAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 799,
+ "src": "18672:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 896,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "18684:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 886,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "18600:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 887,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "converter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 46,
+ "src": "18600:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 885,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "18592:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 884,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "18592:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 888,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18592:27:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "id": 883,
+ "name": "ILegacyConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 26,
+ "src": "18575:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_ILegacyConverter_$26_$",
+ "typeString": "type(contract ILegacyConverter)"
+ }
+ },
+ "id": 889,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18575:45:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_ILegacyConverter_$26",
+ "typeString": "contract ILegacyConverter"
+ }
+ },
+ "id": 890,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "change",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 25,
+ "src": "18575:52:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_nonpayable$_t_contract$_IERC20Token_$21127_$_t_contract$_IERC20Token_$21127_$_t_uint256_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (contract IERC20Token,contract IERC20Token,uint256,uint256) external returns (uint256)"
+ }
+ },
+ "id": 897,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "18575:111:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "18564:122:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 899,
+ "nodeType": "ExpressionStatement",
+ "src": "18564:122:0"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 941,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "19138:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 942,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "processAffiliateFee",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 58,
+ "src": "19138:28:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 968,
+ "nodeType": "IfStatement",
+ "src": "19134:308:0",
+ "trueBody": {
+ "id": 967,
+ "nodeType": "Block",
+ "src": "19168:274:0",
+ "statements": [
+ {
+ "assignments": [
+ 944
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 944,
+ "mutability": "mutable",
+ "name": "affiliateAmount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 967,
+ "src": "19187:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 943,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "19187:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 952,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 950,
+ "name": "PPM_RESOLUTION",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 39,
+ "src": "19245:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 947,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 790,
+ "src": "19226:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 945,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "19213:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 946,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "mul",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22327,
+ "src": "19213:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 948,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "19213:27:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 949,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "div",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22353,
+ "src": "19213:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
+ "typeString": "function (uint256,uint256) pure returns (uint256)"
+ }
+ },
+ "id": 951,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "19213:47:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "19187:73:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 957,
+ "name": "_affiliateAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 788,
+ "src": "19317:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 958,
+ "name": "affiliateAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 944,
+ "src": "19336:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 954,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "19287:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 955,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "19287:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "id": 956,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "transfer",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 21106,
+ "src": "19287:29:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
+ "typeString": "function (address,uint256) external returns (bool)"
+ }
+ },
+ "id": 959,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "19287:65:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f4645455f5452414e534645525f4641494c4544",
+ "id": 960,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "19354:25:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_adc6d664872bc68defa0e975019744f9c0f552331af13f5f130791cee181d10c",
+ "typeString": "literal_string \"ERR_FEE_TRANSFER_FAILED\""
+ },
+ "value": "ERR_FEE_TRANSFER_FAILED"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_adc6d664872bc68defa0e975019744f9c0f552331af13f5f130791cee181d10c",
+ "typeString": "literal_string \"ERR_FEE_TRANSFER_FAILED\""
+ }
+ ],
+ "id": 953,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "19279:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 961,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "19279:101:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 962,
+ "nodeType": "ExpressionStatement",
+ "src": "19279:101:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 965,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 963,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "19399:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "-=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 964,
+ "name": "affiliateAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 944,
+ "src": "19411:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "19399:27:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 966,
+ "nodeType": "ExpressionStatement",
+ "src": "19399:27:0"
+ }
+ ]
+ }
+ },
+ {
+ "eventCall": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 970,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "19474:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 971,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "anchor",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 48,
+ "src": "19474:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 972,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "19491:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 973,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "19491:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 974,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 814,
+ "src": "19513:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 975,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "19513:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 976,
+ "name": "fromAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 799,
+ "src": "19535:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 977,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "19547:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 978,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "19557:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 979,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sender",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "19557:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "id": 969,
+ "name": "Conversion",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 81,
+ "src": "19463:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_event_nonpayable$_t_contract$_IConverterAnchor_$13349_$_t_contract$_IERC20Token_$21127_$_t_contract$_IERC20Token_$21127_$_t_uint256_$_t_uint256_$_t_address_$returns$__$",
+ "typeString": "function (contract IConverterAnchor,contract IERC20Token,contract IERC20Token,uint256,uint256,address)"
+ }
+ },
+ "id": 980,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "19463:105:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 981,
+ "nodeType": "EmitStatement",
+ "src": "19458:110:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 984,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 982,
+ "name": "fromAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 799,
+ "src": "19583:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 983,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "19596:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "19583:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 985,
+ "nodeType": "ExpressionStatement",
+ "src": "19583:21:0"
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 809,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 806,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 803,
+ "src": "17442:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 807,
+ "name": "_data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 782,
+ "src": "17446:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 808,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "17446:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "17442:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 987,
+ "initializationExpression": {
+ "assignments": [
+ 803
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 803,
+ "mutability": "mutable",
+ "name": "i",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 987,
+ "src": "17427:9:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 802,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "17427:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 805,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 804,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "17439:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "17427:13:0"
+ },
+ "loopExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 811,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "++",
+ "prefix": false,
+ "src": "17460:3:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "id": 810,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 803,
+ "src": "17460:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 812,
+ "nodeType": "ExpressionStatement",
+ "src": "17460:3:0"
+ },
+ "nodeType": "ForStatement",
+ "src": "17422:2194:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 991,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 989,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "19700:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 990,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 786,
+ "src": "19712:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "19700:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f52455455524e5f544f4f5f4c4f57",
+ "id": 992,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "19724:20:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_c3237cc40443cfd1e0e9492ef35b7447eab6349fb6eac5eb1ec626edd3c555aa",
+ "typeString": "literal_string \"ERR_RETURN_TOO_LOW\""
+ },
+ "value": "ERR_RETURN_TOO_LOW"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_c3237cc40443cfd1e0e9492ef35b7447eab6349fb6eac5eb1ec626edd3c555aa",
+ "typeString": "literal_string \"ERR_RETURN_TOO_LOW\""
+ }
+ ],
+ "id": 988,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "19692:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 993,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "19692:53:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 994,
+ "nodeType": "ExpressionStatement",
+ "src": "19692:53:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 995,
+ "name": "toAmount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 796,
+ "src": "19765:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 794,
+ "id": 996,
+ "nodeType": "Return",
+ "src": "19758:15:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 779,
+ "nodeType": "StructuredDocumentation",
+ "src": "16471:603:0",
+ "text": " @dev executes the actual conversion by following the conversion path\n @param _data conversion data, see ConversionStep struct above\n @param _amount amount to convert from, in the source token\n @param _minReturn if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero\n @param _affiliateAccount affiliate account\n @param _affiliateFee affiliate fee in PPM\n @return amount of tokens received from the conversion"
+ },
+ "id": 998,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "doConversion",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 791,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 782,
+ "mutability": "mutable",
+ "name": "_data",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 998,
+ "src": "17112:29:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ },
+ "typeName": {
+ "baseType": {
+ "contractScope": null,
+ "id": 780,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "17112:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "id": 781,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "17112:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_storage_$dyn_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 784,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 998,
+ "src": "17152:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 783,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "17152:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 786,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 998,
+ "src": "17178:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 785,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "17178:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 788,
+ "mutability": "mutable",
+ "name": "_affiliateAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 998,
+ "src": "17207:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 787,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "17207:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 790,
+ "mutability": "mutable",
+ "name": "_affiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 998,
+ "src": "17243:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 789,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "17243:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "17101:170:0"
+ },
+ "returnParameters": {
+ "id": 794,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 793,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 998,
+ "src": "17289:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 792,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "17289:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "17288:9:0"
+ },
+ "scope": 1976,
+ "src": "17080:2701:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 1109,
+ "nodeType": "Block",
+ "src": "20232:1606:0",
+ "statements": [
+ {
+ "assignments": [
+ 1009
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1009,
+ "mutability": "mutable",
+ "name": "firstConverter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1109,
+ "src": "20243:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1008,
+ "name": "IConverter",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13340,
+ "src": "20243:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1018,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1013,
+ "name": "_anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1003,
+ "src": "20290:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ "id": 1014,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "owner",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22838,
+ "src": "20290:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_address_$",
+ "typeString": "function () view external returns (address)"
+ }
+ },
+ "id": 1015,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20290:15:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1012,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "20282:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_payable_$",
+ "typeString": "type(address payable)"
+ },
+ "typeName": {
+ "id": 1011,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "20282:8:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1016,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20282:24:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "id": 1010,
+ "name": "IConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 13340,
+ "src": "20271:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IConverter_$13340_$",
+ "typeString": "type(contract IConverter)"
+ }
+ },
+ "id": 1017,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20271:36:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "20243:64:0"
+ },
+ {
+ "assignments": [
+ 1020
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1020,
+ "mutability": "mutable",
+ "name": "isNewerConverter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1109,
+ "src": "20318:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 1019,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "20318:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1024,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1022,
+ "name": "firstConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1009,
+ "src": "20365:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1021,
+ "name": "isV28OrHigherConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1719,
+ "src": "20342:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$returns$_t_bool_$",
+ "typeString": "function (contract IConverter) view returns (bool)"
+ }
+ },
+ "id": 1023,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20342:38:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "20318:62:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1028,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1025,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "20413:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 1026,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "value",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "20413:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1027,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20425:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "20413:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "condition": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1055,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "20955:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 1057,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 1056,
+ "name": "_sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1001,
+ "src": "20967:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "20955:25:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "id": 1106,
+ "nodeType": "Block",
+ "src": "21447:384:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "id": 1082,
+ "name": "isNewerConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1020,
+ "src": "21605:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1095,
+ "name": "_sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1001,
+ "src": "21770:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1096,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "21784:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 1097,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sender",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "21784:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1100,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "21804:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 1099,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "21796:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1098,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "21796:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1101,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21796:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1102,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1005,
+ "src": "21811:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1094,
+ "name": "safeTransferFrom",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22525,
+ "src": "21753:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,address,uint256)"
+ }
+ },
+ "id": 1103,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21753:66:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1104,
+ "nodeType": "ExpressionStatement",
+ "src": "21753:66:0"
+ },
+ "id": 1105,
+ "nodeType": "IfStatement",
+ "src": "21601:218:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1084,
+ "name": "_sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1001,
+ "src": "21657:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1085,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "21671:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 1086,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sender",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "21671:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1089,
+ "name": "firstConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1009,
+ "src": "21691:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1088,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "21683:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1087,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "21683:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1090,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21683:23:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1091,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1005,
+ "src": "21708:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1083,
+ "name": "safeTransferFrom",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22525,
+ "src": "21640:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,address,uint256)"
+ }
+ },
+ "id": 1092,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21640:76:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1093,
+ "nodeType": "ExpressionStatement",
+ "src": "21640:76:0"
+ }
+ }
+ ]
+ },
+ "id": 1107,
+ "nodeType": "IfStatement",
+ "src": "20951:880:0",
+ "trueBody": {
+ "id": 1081,
+ "nodeType": "Block",
+ "src": "20982:420:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1059,
+ "name": "_sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1001,
+ "src": "21184:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1060,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "21198:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 1061,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sender",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "21198:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1064,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "21218:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 1063,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "21210:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1062,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "21210:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1065,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21210:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1066,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1005,
+ "src": "21225:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1058,
+ "name": "safeTransferFrom",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22525,
+ "src": "21167:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,address,uint256)"
+ }
+ },
+ "id": 1067,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21167:66:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1068,
+ "nodeType": "ExpressionStatement",
+ "src": "21167:66:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "id": 1069,
+ "name": "isNewerConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1020,
+ "src": "21303:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1080,
+ "nodeType": "IfStatement",
+ "src": "21299:91:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1077,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1005,
+ "src": "21382:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1073,
+ "name": "_sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1001,
+ "src": "21358:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "id": 1072,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "21350:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1071,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "21350:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1074,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21350:21:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1070,
+ "name": "IEtherToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21153,
+ "src": "21338:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IEtherToken_$21153_$",
+ "typeString": "type(contract IEtherToken)"
+ }
+ },
+ "id": 1075,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21338:34:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ },
+ "id": 1076,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "withdraw",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 21140,
+ "src": "21338:43:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$returns$__$",
+ "typeString": "function (uint256) external"
+ }
+ },
+ "id": 1078,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "21338:52:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1079,
+ "nodeType": "ExpressionStatement",
+ "src": "21338:52:0"
+ }
+ }
+ ]
+ }
+ },
+ "id": 1108,
+ "nodeType": "IfStatement",
+ "src": "20409:1422:0",
+ "trueBody": {
+ "id": 1054,
+ "nodeType": "Block",
+ "src": "20428:485:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1033,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1030,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "20486:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 1031,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "value",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "20486:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 1032,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1005,
+ "src": "20499:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "20486:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f4554485f414d4f554e545f4d49534d41544348",
+ "id": 1034,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "20508:25:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_b27c160ac497b67c4fef6b5554e0b1a41f3c9b44e4bd8482662df760b76c093b",
+ "typeString": "literal_string \"ERR_ETH_AMOUNT_MISMATCH\""
+ },
+ "value": "ERR_ETH_AMOUNT_MISMATCH"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_b27c160ac497b67c4fef6b5554e0b1a41f3c9b44e4bd8482662df760b76c093b",
+ "typeString": "literal_string \"ERR_ETH_AMOUNT_MISMATCH\""
+ }
+ ],
+ "id": 1029,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "20478:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 1035,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20478:56:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1036,
+ "nodeType": "ExpressionStatement",
+ "src": "20478:56:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "id": 1038,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "!",
+ "prefix": true,
+ "src": "20768:17:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "id": 1037,
+ "name": "isNewerConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1020,
+ "src": "20769:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1053,
+ "nodeType": "IfStatement",
+ "src": "20764:137:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1043,
+ "name": "firstConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1009,
+ "src": "20854:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1042,
+ "name": "getConverterEtherTokenAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1552,
+ "src": "20824:29:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$returns$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "function (contract IConverter) view returns (contract IERC20Token)"
+ }
+ },
+ "id": 1044,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20824:45:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "id": 1041,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "20816:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1040,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "20816:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1045,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20816:54:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1039,
+ "name": "IEtherToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21153,
+ "src": "20804:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IEtherToken_$21153_$",
+ "typeString": "type(contract IEtherToken)"
+ }
+ },
+ "id": 1046,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20804:67:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ },
+ "id": 1047,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "deposit",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 21135,
+ "src": "20804:75:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_payable$__$returns$__$",
+ "typeString": "function () payable external"
+ }
+ },
+ "id": 1050,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "names": [
+ "value"
+ ],
+ "nodeType": "FunctionCallOptions",
+ "options": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1048,
+ "name": "msg",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -15,
+ "src": "20888:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_message",
+ "typeString": "msg"
+ }
+ },
+ "id": 1049,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "value",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "20888:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "src": "20804:95:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_payable$__$returns$__$value",
+ "typeString": "function () payable external"
+ }
+ },
+ "id": 1051,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "20804:97:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1052,
+ "nodeType": "ExpressionStatement",
+ "src": "20804:97:0"
+ }
+ }
+ ]
+ }
+ }
+ ]
+ },
+ "documentation": {
+ "id": 999,
+ "nodeType": "StructuredDocumentation",
+ "src": "19789:333:0",
+ "text": " @dev validates msg.value and prepares the conversion source token for the conversion\n @param _sourceToken source token of the first conversion step\n @param _anchor converter anchor of the first conversion step\n @param _amount amount to convert from, in the source token"
+ },
+ "id": 1110,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "handleSourceToken",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1006,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1001,
+ "mutability": "mutable",
+ "name": "_sourceToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1110,
+ "src": "20155:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1000,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "20155:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1003,
+ "mutability": "mutable",
+ "name": "_anchor",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1110,
+ "src": "20181:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1002,
+ "name": "IConverterAnchor",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13349,
+ "src": "20181:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1005,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1110,
+ "src": "20207:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1004,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "20207:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "20154:69:0"
+ },
+ "returnParameters": {
+ "id": 1007,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "20232:0:0"
+ },
+ "scope": 1976,
+ "src": "20128:1710:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 1173,
+ "nodeType": "Block",
+ "src": "22295:780:0",
+ "statements": [
+ {
+ "assignments": [
+ 1122
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1122,
+ "mutability": "mutable",
+ "name": "stepData",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1173,
+ "src": "22306:30:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1121,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "22306:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1129,
+ "initialValue": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1123,
+ "name": "_data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1114,
+ "src": "22339:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1128,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1127,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1124,
+ "name": "_data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1114,
+ "src": "22345:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1125,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "22345:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 1126,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "22360:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "22345:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "22339:23:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "22306:56:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "id": 1136,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1130,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1122,
+ "src": "22444:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1131,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "22444:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "!=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1134,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "22476:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 1133,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "22468:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1132,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "22468:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1135,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "22468:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "src": "22444:37:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1138,
+ "nodeType": "IfStatement",
+ "src": "22440:63:0",
+ "trueBody": {
+ "expression": null,
+ "functionReturnParameters": 1120,
+ "id": 1137,
+ "nodeType": "Return",
+ "src": "22496:7:0"
+ }
+ },
+ {
+ "assignments": [
+ 1140
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1140,
+ "mutability": "mutable",
+ "name": "targetToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1173,
+ "src": "22515:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1139,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "22515:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1143,
+ "initialValue": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1141,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1122,
+ "src": "22541:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1142,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "22541:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "22515:46:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1144,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "22607:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 1146,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 1145,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1140,
+ "src": "22619:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "22607:24:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "id": 1171,
+ "nodeType": "Block",
+ "src": "22993:75:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1166,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1140,
+ "src": "23021:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1167,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1118,
+ "src": "23034:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1168,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1116,
+ "src": "23048:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1165,
+ "name": "safeTransfer",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22475,
+ "src": "23008:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,uint256)"
+ }
+ },
+ "id": 1169,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "23008:48:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1170,
+ "nodeType": "ExpressionStatement",
+ "src": "23008:48:0"
+ }
+ ]
+ },
+ "id": 1172,
+ "nodeType": "IfStatement",
+ "src": "22603:465:0",
+ "trueBody": {
+ "id": 1164,
+ "nodeType": "Block",
+ "src": "22633:315:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1150,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "!",
+ "prefix": true,
+ "src": "22731:32:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1148,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1122,
+ "src": "22732:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1149,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "isV28OrHigherConverter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 56,
+ "src": "22732:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ ],
+ "id": 1147,
+ "name": "assert",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -3,
+ "src": "22724:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_assert_pure$_t_bool_$returns$__$",
+ "typeString": "function (bool) pure"
+ }
+ },
+ "id": 1151,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "22724:40:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1152,
+ "nodeType": "ExpressionStatement",
+ "src": "22724:40:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1160,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1118,
+ "src": "22914:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1161,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1116,
+ "src": "22928:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1156,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1140,
+ "src": "22889:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "id": 1155,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "22881:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1154,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "22881:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1157,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "22881:20:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1153,
+ "name": "IEtherToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21153,
+ "src": "22869:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IEtherToken_$21153_$",
+ "typeString": "type(contract IEtherToken)"
+ }
+ },
+ "id": 1158,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "22869:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IEtherToken_$21153",
+ "typeString": "contract IEtherToken"
+ }
+ },
+ "id": 1159,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "withdrawTo",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 21152,
+ "src": "22869:44:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_nonpayable$_t_address_payable_$_t_uint256_$returns$__$",
+ "typeString": "function (address payable,uint256) external"
+ }
+ },
+ "id": 1162,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "22869:67:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1163,
+ "nodeType": "ExpressionStatement",
+ "src": "22869:67:0"
+ }
+ ]
+ }
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1111,
+ "nodeType": "StructuredDocumentation",
+ "src": "21846:330:0",
+ "text": " @dev handles the conversion target token if the network still holds it at the end of the conversion\n @param _data conversion data, see ConversionStep struct above\n @param _amount conversion target amount\n @param _beneficiary wallet to receive the conversion result"
+ },
+ "id": 1174,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "handleTargetToken",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1119,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1114,
+ "mutability": "mutable",
+ "name": "_data",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1174,
+ "src": "22209:29:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ },
+ "typeName": {
+ "baseType": {
+ "contractScope": null,
+ "id": 1112,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "22209:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "id": 1113,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "22209:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_storage_$dyn_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1116,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1174,
+ "src": "22240:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1115,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "22240:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1118,
+ "mutability": "mutable",
+ "name": "_beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1174,
+ "src": "22257:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 1117,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "22257:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "22208:78:0"
+ },
+ "returnParameters": {
+ "id": 1120,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "22295:0:0"
+ },
+ "scope": 1976,
+ "src": "22182:893:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 1467,
+ "nodeType": "Block",
+ "src": "23760:4093:0",
+ "statements": [
+ {
+ "assignments": [
+ 1191
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1191,
+ "mutability": "mutable",
+ "name": "data",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1467,
+ "src": "23771:28:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ },
+ "typeName": {
+ "baseType": {
+ "contractScope": null,
+ "id": 1189,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "23771:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "id": 1190,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "23771:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_storage_$dyn_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1200,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1198,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1195,
+ "name": "_conversionPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1178,
+ "src": "23823:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 1196,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "23823:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 1197,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "23848:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "23823:26:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1194,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "NewExpression",
+ "src": "23802:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_objectcreation_pure$_t_uint256_$returns$_t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr_$",
+ "typeString": "function (uint256) pure returns (struct BancorNetwork.ConversionStep memory[] memory)"
+ },
+ "typeName": {
+ "baseType": {
+ "contractScope": null,
+ "id": 1192,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "23806:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "id": 1193,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "23806:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_storage_$dyn_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ }
+ }
+ },
+ "id": 1199,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "23802:48:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "23771:79:0"
+ },
+ {
+ "assignments": [
+ 1202
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1202,
+ "mutability": "mutable",
+ "name": "affiliateFeeProcessed",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1467,
+ "src": "23863:26:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 1201,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "23863:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1204,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "66616c7365",
+ "id": 1203,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "23892:5:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "false"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "23863:34:0"
+ },
+ {
+ "assignments": [
+ 1206
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1206,
+ "mutability": "mutable",
+ "name": "bntToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1467,
+ "src": "23908:20:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1205,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "23908:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1212,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1209,
+ "name": "BNT_TOKEN",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21551,
+ "src": "23953:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ ],
+ "id": 1208,
+ "name": "addressOf",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21718,
+ "src": "23943:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$",
+ "typeString": "function (bytes32) view returns (address)"
+ }
+ },
+ "id": 1210,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "23943:20:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1207,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "23931:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 1211,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "23931:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "23908:56:0"
+ },
+ {
+ "assignments": [
+ 1214
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1214,
+ "mutability": "mutable",
+ "name": "i",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1467,
+ "src": "24060:9:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1213,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "24060:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1215,
+ "initialValue": null,
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24060:9:0"
+ },
+ {
+ "body": {
+ "id": 1303,
+ "nodeType": "Block",
+ "src": "24132:1199:0",
+ "statements": [
+ {
+ "assignments": [
+ 1231
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1231,
+ "mutability": "mutable",
+ "name": "anchor",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1303,
+ "src": "24147:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1230,
+ "name": "IConverterAnchor",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13349,
+ "src": "24147:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1239,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1233,
+ "name": "_conversionPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1178,
+ "src": "24190:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 1237,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1236,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1234,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "24206:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 1235,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24210:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "24206:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "24190:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1232,
+ "name": "IConverterAnchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 13349,
+ "src": "24173:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IConverterAnchor_$13349_$",
+ "typeString": "type(contract IConverterAnchor)"
+ }
+ },
+ "id": 1238,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24173:40:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24147:66:0"
+ },
+ {
+ "assignments": [
+ 1241
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1241,
+ "mutability": "mutable",
+ "name": "converter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1303,
+ "src": "24228:20:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1240,
+ "name": "IConverter",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13340,
+ "src": "24228:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1250,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1245,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1231,
+ "src": "24270:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ "id": 1246,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "owner",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 22838,
+ "src": "24270:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_address_$",
+ "typeString": "function () view external returns (address)"
+ }
+ },
+ "id": 1247,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24270:14:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1244,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "24262:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_payable_$",
+ "typeString": "type(address payable)"
+ },
+ "typeName": {
+ "id": 1243,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "24262:8:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1248,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24262:23:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ ],
+ "id": 1242,
+ "name": "IConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 13340,
+ "src": "24251:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IConverter_$13340_$",
+ "typeString": "type(contract IConverter)"
+ }
+ },
+ "id": 1249,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24251:35:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24228:58:0"
+ },
+ {
+ "assignments": [
+ 1252
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1252,
+ "mutability": "mutable",
+ "name": "targetToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1303,
+ "src": "24301:23:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1251,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "24301:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1260,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1254,
+ "name": "_conversionPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1178,
+ "src": "24339:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 1258,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1257,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1255,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "24355:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 1256,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24359:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "24355:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "24339:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1253,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "24327:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 1259,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24327:35:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24301:61:0"
+ },
+ {
+ "assignments": [
+ 1262
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1262,
+ "mutability": "mutable",
+ "name": "processAffiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1303,
+ "src": "24455:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 1261,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "24455:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1271,
+ "initialValue": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 1270,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 1266,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1263,
+ "name": "_affiliateFeeEnabled",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1182,
+ "src": "24482:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 1265,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "!",
+ "prefix": true,
+ "src": "24506:22:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "id": 1264,
+ "name": "affiliateFeeProcessed",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1202,
+ "src": "24507:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "24482:46:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "id": 1269,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1267,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1252,
+ "src": "24532:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 1268,
+ "name": "bntToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1206,
+ "src": "24547:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "24532:23:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "24482:73:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "24455:100:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "id": 1272,
+ "name": "processAffiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1262,
+ "src": "24574:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1277,
+ "nodeType": "IfStatement",
+ "src": "24570:70:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1275,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 1273,
+ "name": "affiliateFeeProcessed",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1202,
+ "src": "24612:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "74727565",
+ "id": 1274,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24636:4:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "true"
+ },
+ "src": "24612:28:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 1276,
+ "nodeType": "ExpressionStatement",
+ "src": "24612:28:0"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1301,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1278,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "24657:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1282,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1281,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1279,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "24662:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "/",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 1280,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24666:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "24662:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "nodeType": "IndexAccess",
+ "src": "24657:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1284,
+ "name": "anchor",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1231,
+ "src": "24758:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1285,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1241,
+ "src": "24834:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1287,
+ "name": "_conversionPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1178,
+ "src": "24938:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 1289,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 1288,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "24954:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "24938:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1286,
+ "name": "IERC20Token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21127,
+ "src": "24926:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "type(contract IERC20Token)"
+ }
+ },
+ "id": 1290,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "24926:31:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1291,
+ "name": "targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1252,
+ "src": "24989:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1294,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "25134:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1293,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "25126:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1292,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "25126:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1295,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "25126:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1297,
+ "name": "converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1241,
+ "src": "25234:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1296,
+ "name": "isV28OrHigherConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1719,
+ "src": "25211:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$returns$_t_bool_$",
+ "typeString": "function (contract IConverter) view returns (bool)"
+ }
+ },
+ "id": 1298,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "25211:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1299,
+ "name": "processAffiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1262,
+ "src": "25284:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverterAnchor_$13349",
+ "typeString": "contract IConverterAnchor"
+ },
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ ],
+ "id": 1283,
+ "name": "ConversionStep",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 59,
+ "src": "24671:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_struct$_ConversionStep_$59_storage_ptr_$",
+ "typeString": "type(struct BancorNetwork.ConversionStep storage pointer)"
+ }
+ },
+ "id": 1300,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "structConstructorCall",
+ "lValueRequested": false,
+ "names": [
+ "anchor",
+ "converter",
+ "sourceToken",
+ "targetToken",
+ "beneficiary",
+ "isV28OrHigherConverter",
+ "processAffiliateFee"
+ ],
+ "nodeType": "FunctionCall",
+ "src": "24671:648:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "src": "24657:662:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1302,
+ "nodeType": "ExpressionStatement",
+ "src": "24657:662:0"
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1225,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1220,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "24092:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1224,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1221,
+ "name": "_conversionPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1178,
+ "src": "24096:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ "id": 1222,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "24096:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 1223,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24121:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "24096:26:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "24092:30:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 1304,
+ "initializationExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1218,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 1216,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "24085:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1217,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24089:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "24085:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 1219,
+ "nodeType": "ExpressionStatement",
+ "src": "24085:5:0"
+ },
+ "loopExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1228,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 1226,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "24124:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "+=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "32",
+ "id": 1227,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "24129:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_2_by_1",
+ "typeString": "int_const 2"
+ },
+ "value": "2"
+ },
+ "src": "24124:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 1229,
+ "nodeType": "ExpressionStatement",
+ "src": "24124:6:0"
+ },
+ "nodeType": "ForStatement",
+ "src": "24080:1251:0"
+ },
+ {
+ "assignments": [
+ 1306
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1306,
+ "mutability": "mutable",
+ "name": "stepData",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1467,
+ "src": "25393:30:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1305,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "25393:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1310,
+ "initialValue": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1307,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "25426:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1309,
+ "indexExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1308,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "25431:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "25426:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "25393:40:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1311,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "25448:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 1314,
+ "indexExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1312,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "25460:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1313,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "25460:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "25448:33:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1334,
+ "nodeType": "IfStatement",
+ "src": "25444:472:0",
+ "trueBody": {
+ "id": 1333,
+ "nodeType": "Block",
+ "src": "25483:433:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1315,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "25594:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1316,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "isV28OrHigherConverter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 56,
+ "src": "25594:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1330,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1323,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "25832:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1325,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "25832:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1327,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "25885:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1328,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "converter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 46,
+ "src": "25885:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1326,
+ "name": "getConverterEtherTokenAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1552,
+ "src": "25855:29:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$returns$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "function (contract IConverter) view returns (contract IERC20Token)"
+ }
+ },
+ "id": 1329,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "25855:49:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "25832:72:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "id": 1331,
+ "nodeType": "ExpressionStatement",
+ "src": "25832:72:0"
+ },
+ "id": 1332,
+ "nodeType": "IfStatement",
+ "src": "25590:314:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1321,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1317,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "25644:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1319,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "sourceToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 50,
+ "src": "25644:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 1320,
+ "name": "ETH_RESERVE_ADDRESS",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 44,
+ "src": "25667:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "25644:42:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "id": 1322,
+ "nodeType": "ExpressionStatement",
+ "src": "25644:42:0"
+ }
+ }
+ ]
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1342,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 1335,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "25954:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1336,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "25965:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1341,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1340,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1337,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "25970:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1338,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "25970:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 1339,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "25984:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "25970:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "25965:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "src": "25954:32:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1343,
+ "nodeType": "ExpressionStatement",
+ "src": "25954:32:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1344,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "26001:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 1347,
+ "indexExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1345,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26013:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1346,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "26013:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "26001:33:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1367,
+ "nodeType": "IfStatement",
+ "src": "25997:472:0",
+ "trueBody": {
+ "id": 1366,
+ "nodeType": "Block",
+ "src": "26036:433:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1348,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26147:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1349,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "isV28OrHigherConverter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 56,
+ "src": "26147:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1363,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1356,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26385:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1358,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "26385:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1360,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26438:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1361,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "converter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 46,
+ "src": "26438:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1359,
+ "name": "getConverterEtherTokenAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1552,
+ "src": "26408:29:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$returns$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "function (contract IConverter) view returns (contract IERC20Token)"
+ }
+ },
+ "id": 1362,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "26408:49:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "26385:72:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "id": 1364,
+ "nodeType": "ExpressionStatement",
+ "src": "26385:72:0"
+ },
+ "id": 1365,
+ "nodeType": "IfStatement",
+ "src": "26143:314:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1354,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1350,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26197:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1352,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "targetToken",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 52,
+ "src": "26197:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 1353,
+ "name": "ETH_RESERVE_ADDRESS",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 44,
+ "src": "26220:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "26197:42:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "id": 1355,
+ "nodeType": "ExpressionStatement",
+ "src": "26197:42:0"
+ }
+ }
+ ]
+ }
+ },
+ {
+ "body": {
+ "id": 1463,
+ "nodeType": "Block",
+ "src": "26561:1261:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1383,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 1379,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26576:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1380,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "26587:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1382,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 1381,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "26592:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "26587:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "src": "26576:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1384,
+ "nodeType": "ExpressionStatement",
+ "src": "26576:18:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1385,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26746:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1386,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "isV28OrHigherConverter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 56,
+ "src": "26746:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "id": 1461,
+ "nodeType": "Block",
+ "src": "27642:169:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1459,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1449,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "27750:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1451,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "27750:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1456,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "27789:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 1455,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "27781:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1454,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "27781:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1457,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "27781:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1453,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "27773:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_payable_$",
+ "typeString": "type(address payable)"
+ },
+ "typeName": {
+ "id": 1452,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "27773:8:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1458,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "27773:22:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "src": "27750:45:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "id": 1460,
+ "nodeType": "ExpressionStatement",
+ "src": "27750:45:0"
+ }
+ ]
+ },
+ "id": 1462,
+ "nodeType": "IfStatement",
+ "src": "26742:1069:0",
+ "trueBody": {
+ "id": 1448,
+ "nodeType": "Block",
+ "src": "26779:844:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1387,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26902:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1388,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "processAffiliateFee",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 58,
+ "src": "26902:28:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1406,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1401,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "27106:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1405,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1402,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "27111:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1403,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "27111:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "-",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 1404,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27125:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "27111:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "27106:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "condition": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1413,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "27310:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1417,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1416,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1414,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "27315:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 1415,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27319:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "27315:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "27310:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1418,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "isV28OrHigherConverter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 56,
+ "src": "27310:34:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1443,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1433,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "27562:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1435,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "27562:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1440,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "27601:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 1439,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "27593:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1438,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "27593:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1441,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "27593:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1437,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "27585:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_payable_$",
+ "typeString": "type(address payable)"
+ },
+ "typeName": {
+ "id": 1436,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "27585:8:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1442,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "27585:22:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "src": "27562:45:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "id": 1444,
+ "nodeType": "ExpressionStatement",
+ "src": "27562:45:0"
+ },
+ "id": 1445,
+ "nodeType": "IfStatement",
+ "src": "27306:301:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1431,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1419,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "27367:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1421,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "27367:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1424,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "27398:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1428,
+ "indexExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1427,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1425,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "27403:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "+",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "31",
+ "id": 1426,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "27407:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_1_by_1",
+ "typeString": "int_const 1"
+ },
+ "value": "1"
+ },
+ "src": "27403:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "27398:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1429,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "converter",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 46,
+ "src": "27398:21:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1423,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "27390:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1422,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "27390:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1430,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "27390:30:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "src": "27367:53:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "id": 1432,
+ "nodeType": "ExpressionStatement",
+ "src": "27367:53:0"
+ }
+ },
+ "id": 1446,
+ "nodeType": "IfStatement",
+ "src": "27102:505:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1411,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1407,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "27149:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1409,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "27149:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 1410,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1180,
+ "src": "27172:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "src": "27149:35:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "id": 1412,
+ "nodeType": "ExpressionStatement",
+ "src": "27149:35:0"
+ }
+ },
+ "id": 1447,
+ "nodeType": "IfStatement",
+ "src": "26898:709:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1399,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1389,
+ "name": "stepData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1306,
+ "src": "26953:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory"
+ }
+ },
+ "id": 1391,
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": true,
+ "memberName": "beneficiary",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 54,
+ "src": "26953:20:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1396,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "26992:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 1395,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "26984:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1394,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "26984:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1397,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "26984:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "id": 1393,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "26976:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_payable_$",
+ "typeString": "type(address payable)"
+ },
+ "typeName": {
+ "id": 1392,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "26976:8:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1398,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "26976:22:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "src": "26953:45:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "id": 1400,
+ "nodeType": "ExpressionStatement",
+ "src": "26953:45:0"
+ }
+ }
+ ]
+ }
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1375,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1372,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "26539:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1373,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "26543:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "id": 1374,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "26543:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "26539:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 1464,
+ "initializationExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1370,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 1368,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "26532:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1369,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "26536:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "26532:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 1371,
+ "nodeType": "ExpressionStatement",
+ "src": "26532:5:0"
+ },
+ "loopExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1377,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "++",
+ "prefix": false,
+ "src": "26556:3:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "id": 1376,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1214,
+ "src": "26556:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 1378,
+ "nodeType": "ExpressionStatement",
+ "src": "26556:3:0"
+ },
+ "nodeType": "ForStatement",
+ "src": "26527:1295:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1465,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1191,
+ "src": "27841:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep memory[] memory"
+ }
+ },
+ "functionReturnParameters": 1187,
+ "id": 1466,
+ "nodeType": "Return",
+ "src": "27834:11:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1175,
+ "nodeType": "StructuredDocumentation",
+ "src": "23083:503:0",
+ "text": " @dev creates a memory cache of all conversion steps data to minimize logic and external calls during conversions\n @param _conversionPath conversion path, see conversion path format above\n @param _beneficiary wallet to receive the conversion result\n @param _affiliateFeeEnabled true if affiliate fee was requested by the sender, false if not\n @return cached conversion data to be ingested later on by the conversion flow"
+ },
+ "id": 1468,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "createConversionData",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1183,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1178,
+ "mutability": "mutable",
+ "name": "_conversionPath",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1468,
+ "src": "23622:32:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1176,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "23622:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1177,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "23622:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1180,
+ "mutability": "mutable",
+ "name": "_beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1468,
+ "src": "23656:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 1179,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "23656:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1182,
+ "mutability": "mutable",
+ "name": "_affiliateFeeEnabled",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1468,
+ "src": "23686:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 1181,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "23686:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "23621:91:0"
+ },
+ "returnParameters": {
+ "id": 1187,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1186,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1468,
+ "src": "23735:23:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_memory_ptr_$dyn_memory_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ },
+ "typeName": {
+ "baseType": {
+ "contractScope": null,
+ "id": 1184,
+ "name": "ConversionStep",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 59,
+ "src": "23735:14:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_ConversionStep_$59_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep"
+ }
+ },
+ "id": 1185,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "23735:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_struct$_ConversionStep_$59_storage_$dyn_storage_ptr",
+ "typeString": "struct BancorNetwork.ConversionStep[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "23734:25:0"
+ },
+ "scope": 1976,
+ "src": "23592:4261:0",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 1510,
+ "nodeType": "Block",
+ "src": "28406:261:0",
+ "statements": [
+ {
+ "assignments": [
+ 1479
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1479,
+ "mutability": "mutable",
+ "name": "allowance",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1510,
+ "src": "28417:17:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1478,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "28417:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1488,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1484,
+ "name": "this",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -28,
+ "src": "28462:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_BancorNetwork_$1976",
+ "typeString": "contract BancorNetwork"
+ }
+ ],
+ "id": 1483,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "28454:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1482,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "28454:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1485,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28454:13:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1486,
+ "name": "_spender",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1473,
+ "src": "28469:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1480,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1471,
+ "src": "28437:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "id": 1481,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "allowance",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 21097,
+ "src": "28437:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$",
+ "typeString": "function (address,address) view external returns (uint256)"
+ }
+ },
+ "id": 1487,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28437:41:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "28417:61:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1491,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1489,
+ "name": "allowance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1479,
+ "src": "28493:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 1490,
+ "name": "_value",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1475,
+ "src": "28505:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "28493:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1509,
+ "nodeType": "IfStatement",
+ "src": "28489:171:0",
+ "trueBody": {
+ "id": 1508,
+ "nodeType": "Block",
+ "src": "28513:147:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1494,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1492,
+ "name": "allowance",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1479,
+ "src": "28532:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": ">",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1493,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "28544:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "src": "28532:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1501,
+ "nodeType": "IfStatement",
+ "src": "28528:68:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1496,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1471,
+ "src": "28576:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1497,
+ "name": "_spender",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1473,
+ "src": "28584:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1498,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "28594:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1495,
+ "name": "safeApprove",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22428,
+ "src": "28564:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,uint256)"
+ }
+ },
+ "id": 1499,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28564:32:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1500,
+ "nodeType": "ExpressionStatement",
+ "src": "28564:32:0"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1503,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1471,
+ "src": "28623:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1504,
+ "name": "_spender",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1473,
+ "src": "28631:8:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1505,
+ "name": "_value",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1475,
+ "src": "28641:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1502,
+ "name": "safeApprove",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22428,
+ "src": "28611:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20Token_$21127_$_t_address_$_t_uint256_$returns$__$",
+ "typeString": "function (contract IERC20Token,address,uint256)"
+ }
+ },
+ "id": 1506,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28611:37:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 1507,
+ "nodeType": "ExpressionStatement",
+ "src": "28611:37:0"
+ }
+ ]
+ }
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1469,
+ "nodeType": "StructuredDocumentation",
+ "src": "27861:452:0",
+ "text": " @dev utility, checks whether allowance for the given spender exists and approves one if it doesn't.\n Note that we use the non standard erc-20 interface in which `approve` has no return value so that\n this function will work for both standard and non standard tokens\n @param _token token to check the allowance in\n @param _spender approved address\n @param _value allowance amount"
+ },
+ "id": 1511,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "ensureAllowance",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1476,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1471,
+ "mutability": "mutable",
+ "name": "_token",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1511,
+ "src": "28344:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1470,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "28344:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1473,
+ "mutability": "mutable",
+ "name": "_spender",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1511,
+ "src": "28364:16:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 1472,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "28364:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1475,
+ "mutability": "mutable",
+ "name": "_value",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1511,
+ "src": "28382:14:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1474,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "28382:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "28343:54:0"
+ },
+ "returnParameters": {
+ "id": 1477,
+ "nodeType": "ParameterList",
+ "parameters": [],
+ "src": "28406:0:0"
+ },
+ "scope": 1976,
+ "src": "28319:348:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 1551,
+ "nodeType": "Block",
+ "src": "28848:352:0",
+ "statements": [
+ {
+ "assignments": [
+ 1519
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1519,
+ "mutability": "mutable",
+ "name": "reserveCount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1551,
+ "src": "28859:20:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1518,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "28859:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1523,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [],
+ "expression": {
+ "argumentTypes": [],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1520,
+ "name": "_converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1513,
+ "src": "28882:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 1521,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "connectorTokenCount",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13339,
+ "src": "28882:30:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$__$returns$_t_uint16_$",
+ "typeString": "function () view external returns (uint16)"
+ }
+ },
+ "id": 1522,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "28882:32:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint16",
+ "typeString": "uint16"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "28859:55:0"
+ },
+ {
+ "body": {
+ "id": 1547,
+ "nodeType": "Block",
+ "src": "28968:186:0",
+ "statements": [
+ {
+ "assignments": [
+ 1535
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1535,
+ "mutability": "mutable",
+ "name": "reserveTokenAddress",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1547,
+ "src": "28983:31:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1534,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "28983:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1540,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1538,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1525,
+ "src": "29044:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1536,
+ "name": "_converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1513,
+ "src": "29017:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "id": 1537,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "connectorTokens",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": 13334,
+ "src": "29017:26:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "function (uint256) view external returns (contract IERC20Token)"
+ }
+ },
+ "id": 1539,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29017:29:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "28983:63:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1541,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "29065:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 1543,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 1542,
+ "name": "reserveTokenAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1535,
+ "src": "29077:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "29065:32:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1546,
+ "nodeType": "IfStatement",
+ "src": "29061:81:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1544,
+ "name": "reserveTokenAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1535,
+ "src": "29123:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "functionReturnParameters": 1517,
+ "id": 1545,
+ "nodeType": "Return",
+ "src": "29116:26:0"
+ }
+ }
+ ]
+ },
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1530,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1528,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1525,
+ "src": "28945:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 1529,
+ "name": "reserveCount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1519,
+ "src": "28949:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "28945:16:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "id": 1548,
+ "initializationExpression": {
+ "assignments": [
+ 1525
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1525,
+ "mutability": "mutable",
+ "name": "i",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1548,
+ "src": "28930:9:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1524,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "28930:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1527,
+ "initialValue": {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1526,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "28942:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "28930:13:0"
+ },
+ "loopExpression": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1532,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "++",
+ "prefix": false,
+ "src": "28963:3:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "id": 1531,
+ "name": "i",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1525,
+ "src": "28963:1:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 1533,
+ "nodeType": "ExpressionStatement",
+ "src": "28963:3:0"
+ },
+ "nodeType": "ForStatement",
+ "src": "28925:229:0"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1549,
+ "name": "ETH_RESERVE_ADDRESS",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 44,
+ "src": "29173:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "functionReturnParameters": 1517,
+ "id": 1550,
+ "nodeType": "Return",
+ "src": "29166:26:0"
+ }
+ ]
+ },
+ "documentation": null,
+ "id": 1552,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "getConverterEtherTokenAddress",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1514,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1513,
+ "mutability": "mutable",
+ "name": "_converter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1552,
+ "src": "28790:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1512,
+ "name": "IConverter",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13340,
+ "src": "28790:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "28789:23:0"
+ },
+ "returnParameters": {
+ "id": 1517,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1516,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1552,
+ "src": "28835:11:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1515,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "28835:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "28834:13:0"
+ },
+ "scope": 1976,
+ "src": "28751:449:0",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 1578,
+ "nodeType": "Block",
+ "src": "29474:224:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "id": 1564,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "UnaryOperation",
+ "operator": "!",
+ "prefix": true,
+ "src": "29489:20:0",
+ "subExpression": {
+ "argumentTypes": null,
+ "baseExpression": {
+ "argumentTypes": null,
+ "id": 1561,
+ "name": "etherTokens",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 66,
+ "src": "29490:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_contract$_IERC20Token_$21127_$_t_bool_$",
+ "typeString": "mapping(contract IERC20Token => bool)"
+ }
+ },
+ "id": 1563,
+ "indexExpression": {
+ "argumentTypes": null,
+ "id": 1562,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1556,
+ "src": "29502:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "isConstant": false,
+ "isLValue": true,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "IndexAccess",
+ "src": "29490:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1567,
+ "nodeType": "IfStatement",
+ "src": "29485:52:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1565,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1556,
+ "src": "29531:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "functionReturnParameters": 1560,
+ "id": 1566,
+ "nodeType": "Return",
+ "src": "29524:13:0"
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1569,
+ "name": "_converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1554,
+ "src": "29577:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1568,
+ "name": "isV28OrHigherConverter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1719,
+ "src": "29554:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$returns$_t_bool_$",
+ "typeString": "function (contract IConverter) view returns (bool)"
+ }
+ },
+ "id": 1570,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29554:34:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1573,
+ "nodeType": "IfStatement",
+ "src": "29550:79:0",
+ "trueBody": {
+ "expression": {
+ "argumentTypes": null,
+ "id": 1571,
+ "name": "ETH_RESERVE_ADDRESS",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 44,
+ "src": "29610:19:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "functionReturnParameters": 1560,
+ "id": 1572,
+ "nodeType": "Return",
+ "src": "29603:26:0"
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1575,
+ "name": "_converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1554,
+ "src": "29679:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1574,
+ "name": "getConverterEtherTokenAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1552,
+ "src": "29649:29:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_contract$_IConverter_$13340_$returns$_t_contract$_IERC20Token_$21127_$",
+ "typeString": "function (contract IConverter) view returns (contract IERC20Token)"
+ }
+ },
+ "id": 1576,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29649:41:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "functionReturnParameters": 1560,
+ "id": 1577,
+ "nodeType": "Return",
+ "src": "29642:48:0"
+ }
+ ]
+ },
+ "documentation": null,
+ "id": 1579,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "getConverterTokenAddress",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1557,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1554,
+ "mutability": "mutable",
+ "name": "_converter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1579,
+ "src": "29396:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1553,
+ "name": "IConverter",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13340,
+ "src": "29396:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1556,
+ "mutability": "mutable",
+ "name": "_token",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1579,
+ "src": "29419:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1555,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "29419:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "29395:43:0"
+ },
+ "returnParameters": {
+ "id": 1560,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1559,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1579,
+ "src": "29461:11:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1558,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "29461:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "29460:13:0"
+ },
+ "scope": 1976,
+ "src": "29362:336:0",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "private"
+ },
+ {
+ "constant": true,
+ "id": 1587,
+ "mutability": "constant",
+ "name": "GET_RETURN_FUNC_SELECTOR",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1976,
+ "src": "29706:106:0",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ },
+ "typeName": {
+ "id": 1580,
+ "name": "bytes4",
+ "nodeType": "ElementaryTypeName",
+ "src": "29706:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "67657452657475726e28616464726573732c616464726573732c75696e7432353629",
+ "id": 1584,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "29774:36:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_1e1401f8329fe5eb5c7e76277d3c971ffeee3a41a0eef7c00afeb0a286cef0af",
+ "typeString": "literal_string \"getReturn(address,address,uint256)\""
+ },
+ "value": "getReturn(address,address,uint256)"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_stringliteral_1e1401f8329fe5eb5c7e76277d3c971ffeee3a41a0eef7c00afeb0a286cef0af",
+ "typeString": "literal_string \"getReturn(address,address,uint256)\""
+ }
+ ],
+ "id": 1583,
+ "name": "keccak256",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -8,
+ "src": "29764:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_keccak256_pure$_t_bytes_memory_ptr_$returns$_t_bytes32_$",
+ "typeString": "function (bytes memory) pure returns (bytes32)"
+ }
+ },
+ "id": 1585,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29764:47:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ ],
+ "id": 1582,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "29757:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_bytes4_$",
+ "typeString": "type(bytes4)"
+ },
+ "typeName": {
+ "id": 1581,
+ "name": "bytes4",
+ "nodeType": "ElementaryTypeName",
+ "src": "29757:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1586,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "29757:55:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ }
+ },
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 1663,
+ "nodeType": "Block",
+ "src": "30036:523:0",
+ "statements": [
+ {
+ "assignments": [
+ 1603
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1603,
+ "mutability": "mutable",
+ "name": "data",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1663,
+ "src": "30047:17:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes"
+ },
+ "typeName": {
+ "id": 1602,
+ "name": "bytes",
+ "nodeType": "ElementaryTypeName",
+ "src": "30047:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_storage_ptr",
+ "typeString": "bytes"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1611,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1606,
+ "name": "GET_RETURN_FUNC_SELECTOR",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1587,
+ "src": "30090:24:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1607,
+ "name": "_sourceToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1591,
+ "src": "30116:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1608,
+ "name": "_targetToken",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1593,
+ "src": "30130:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1609,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1595,
+ "src": "30144:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1604,
+ "name": "abi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -1,
+ "src": "30067:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_abi",
+ "typeString": "abi"
+ }
+ },
+ "id": 1605,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "memberName": "encodeWithSelector",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "30067:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$",
+ "typeString": "function (bytes4) pure returns (bytes memory)"
+ }
+ },
+ "id": 1610,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30067:85:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "30047:105:0"
+ },
+ {
+ "assignments": [
+ 1613,
+ 1615
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1613,
+ "mutability": "mutable",
+ "name": "success",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1663,
+ "src": "30164:12:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 1612,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "30164:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1615,
+ "mutability": "mutable",
+ "name": "returnData",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1663,
+ "src": "30178:23:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes"
+ },
+ "typeName": {
+ "id": 1614,
+ "name": "bytes",
+ "nodeType": "ElementaryTypeName",
+ "src": "30178:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_storage_ptr",
+ "typeString": "bytes"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1623,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1621,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1603,
+ "src": "30231:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1618,
+ "name": "_dest",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1589,
+ "src": "30213:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1617,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "30205:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1616,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "30205:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1619,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30205:14:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "id": 1620,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "staticcall",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "30205:25:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_barestaticcall_view$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$",
+ "typeString": "function (bytes memory) view returns (bool,bytes memory)"
+ }
+ },
+ "id": 1622,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30205:31:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$",
+ "typeString": "tuple(bool,bytes memory)"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "30163:73:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "id": 1624,
+ "name": "success",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1613,
+ "src": "30253:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1658,
+ "nodeType": "IfStatement",
+ "src": "30249:277:0",
+ "trueBody": {
+ "id": 1657,
+ "nodeType": "Block",
+ "src": "30262:264:0",
+ "statements": [
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1628,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1625,
+ "name": "returnData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1615,
+ "src": "30281:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ },
+ "id": 1626,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "30281:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3634",
+ "id": 1627,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "30302:2:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_64_by_1",
+ "typeString": "int_const 64"
+ },
+ "value": "64"
+ },
+ "src": "30281:23:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1640,
+ "nodeType": "IfStatement",
+ "src": "30277:113:0",
+ "trueBody": {
+ "id": 1639,
+ "nodeType": "Block",
+ "src": "30306:84:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1631,
+ "name": "returnData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1615,
+ "src": "30343:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 1633,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "30356:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_uint256_$",
+ "typeString": "type(uint256)"
+ },
+ "typeName": {
+ "id": 1632,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30356:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1635,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "30365:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_uint256_$",
+ "typeString": "type(uint256)"
+ },
+ "typeName": {
+ "id": 1634,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30365:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ }
+ ],
+ "id": 1636,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "30355:18:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_type$_t_uint256_$_$_t_type$_t_uint256_$_$",
+ "typeString": "tuple(type(uint256),type(uint256))"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ },
+ {
+ "typeIdentifier": "t_tuple$_t_type$_t_uint256_$_$_t_type$_t_uint256_$_$",
+ "typeString": "tuple(type(uint256),type(uint256))"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1629,
+ "name": "abi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -1,
+ "src": "30332:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_abi",
+ "typeString": "abi"
+ }
+ },
+ "id": 1630,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "memberName": "decode",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "30332:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_abidecode_pure$__$returns$__$",
+ "typeString": "function () pure"
+ }
+ },
+ "id": 1637,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30332:42:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$",
+ "typeString": "tuple(uint256,uint256)"
+ }
+ },
+ "functionReturnParameters": 1601,
+ "id": 1638,
+ "nodeType": "Return",
+ "src": "30325:49:0"
+ }
+ ]
+ }
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1644,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1641,
+ "name": "returnData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1615,
+ "src": "30410:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ },
+ "id": 1642,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "30410:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3332",
+ "id": 1643,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "30431:2:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_32_by_1",
+ "typeString": "int_const 32"
+ },
+ "value": "32"
+ },
+ "src": "30410:23:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1656,
+ "nodeType": "IfStatement",
+ "src": "30406:109:0",
+ "trueBody": {
+ "id": 1655,
+ "nodeType": "Block",
+ "src": "30435:80:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1647,
+ "name": "returnData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1615,
+ "src": "30473:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 1649,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "30486:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_uint256_$",
+ "typeString": "type(uint256)"
+ },
+ "typeName": {
+ "id": 1648,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30486:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ }
+ ],
+ "id": 1650,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "30485:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_uint256_$",
+ "typeString": "type(uint256)"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ },
+ {
+ "typeIdentifier": "t_type$_t_uint256_$",
+ "typeString": "type(uint256)"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1645,
+ "name": "abi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -1,
+ "src": "30462:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_abi",
+ "typeString": "abi"
+ }
+ },
+ "id": 1646,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "memberName": "decode",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "30462:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_abidecode_pure$__$returns$__$",
+ "typeString": "function () pure"
+ }
+ },
+ "id": 1651,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30462:33:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1652,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "30497:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "id": 1653,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "30461:38:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_rational_0_by_1_$",
+ "typeString": "tuple(uint256,int_const 0)"
+ }
+ },
+ "functionReturnParameters": 1601,
+ "id": 1654,
+ "nodeType": "Return",
+ "src": "30454:45:0"
+ }
+ ]
+ }
+ }
+ ]
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1659,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "30546:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1660,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "30549:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "id": 1661,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "30545:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_rational_0_by_1_$_t_rational_0_by_1_$",
+ "typeString": "tuple(int_const 0,int_const 0)"
+ }
+ },
+ "functionReturnParameters": 1601,
+ "id": 1662,
+ "nodeType": "Return",
+ "src": "30538:13:0"
+ }
+ ]
+ },
+ "documentation": null,
+ "id": 1664,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "getReturn",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1596,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1589,
+ "mutability": "mutable",
+ "name": "_dest",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1664,
+ "src": "29908:16:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1588,
+ "name": "IConverter",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13340,
+ "src": "29908:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1591,
+ "mutability": "mutable",
+ "name": "_sourceToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1664,
+ "src": "29926:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1590,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "29926:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1593,
+ "mutability": "mutable",
+ "name": "_targetToken",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1664,
+ "src": "29952:24:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1592,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "29952:11:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1595,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1664,
+ "src": "29978:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1594,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "29978:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "29907:87:0"
+ },
+ "returnParameters": {
+ "id": 1601,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1598,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1664,
+ "src": "30018:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1597,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30018:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1600,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1664,
+ "src": "30027:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1599,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "30027:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "30017:18:0"
+ },
+ "scope": 1976,
+ "src": "29889:670:0",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "constant": true,
+ "id": 1672,
+ "mutability": "constant",
+ "name": "IS_V28_OR_HIGHER_FUNC_SELECTOR",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1976,
+ "src": "30567:93:0",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ },
+ "typeName": {
+ "id": 1665,
+ "name": "bytes4",
+ "nodeType": "ElementaryTypeName",
+ "src": "30567:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "69735632384f724869676865722829",
+ "id": 1669,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "30641:17:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_d260529c8620a59d78f2e58cfd1294673bb6cba228ad1f34ac7731003ab870dd",
+ "typeString": "literal_string \"isV28OrHigher()\""
+ },
+ "value": "isV28OrHigher()"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_stringliteral_d260529c8620a59d78f2e58cfd1294673bb6cba228ad1f34ac7731003ab870dd",
+ "typeString": "literal_string \"isV28OrHigher()\""
+ }
+ ],
+ "id": 1668,
+ "name": "keccak256",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -8,
+ "src": "30631:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_keccak256_pure$_t_bytes_memory_ptr_$returns$_t_bytes32_$",
+ "typeString": "function (bytes memory) pure returns (bytes32)"
+ }
+ },
+ "id": 1670,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30631:28:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ ],
+ "id": 1667,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "30624:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_bytes4_$",
+ "typeString": "type(bytes4)"
+ },
+ "typeName": {
+ "id": 1666,
+ "name": "bytes4",
+ "nodeType": "ElementaryTypeName",
+ "src": "30624:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1671,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30624:36:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ }
+ },
+ "visibility": "private"
+ },
+ {
+ "body": {
+ "id": 1718,
+ "nodeType": "Block",
+ "src": "30917:336:0",
+ "statements": [
+ {
+ "assignments": [
+ 1680
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1680,
+ "mutability": "mutable",
+ "name": "data",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1718,
+ "src": "30928:17:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes"
+ },
+ "typeName": {
+ "id": 1679,
+ "name": "bytes",
+ "nodeType": "ElementaryTypeName",
+ "src": "30928:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_storage_ptr",
+ "typeString": "bytes"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1685,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1683,
+ "name": "IS_V28_OR_HIGHER_FUNC_SELECTOR",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1672,
+ "src": "30971:30:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes4",
+ "typeString": "bytes4"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1681,
+ "name": "abi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -1,
+ "src": "30948:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_abi",
+ "typeString": "abi"
+ }
+ },
+ "id": 1682,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "memberName": "encodeWithSelector",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "30948:22:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$",
+ "typeString": "function (bytes4) pure returns (bytes memory)"
+ }
+ },
+ "id": 1684,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "30948:54:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "30928:74:0"
+ },
+ {
+ "assignments": [
+ 1687,
+ 1689
+ ],
+ "declarations": [
+ {
+ "constant": false,
+ "id": 1687,
+ "mutability": "mutable",
+ "name": "success",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1718,
+ "src": "31014:12:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 1686,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "31014:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1689,
+ "mutability": "mutable",
+ "name": "returnData",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1718,
+ "src": "31028:23:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes"
+ },
+ "typeName": {
+ "id": 1688,
+ "name": "bytes",
+ "nodeType": "ElementaryTypeName",
+ "src": "31028:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_storage_ptr",
+ "typeString": "bytes"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "id": 1699,
+ "initialValue": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1697,
+ "name": "data",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1680,
+ "src": "31099:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1692,
+ "name": "_converter",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1674,
+ "src": "31063:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ ],
+ "id": 1691,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "31055:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1690,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "31055:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1693,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "31055:19:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "id": 1694,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "staticcall",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "31055:30:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_barestaticcall_view$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$",
+ "typeString": "function (bytes memory) view returns (bool,bytes memory)"
+ }
+ },
+ "id": 1696,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "names": [
+ "gas"
+ ],
+ "nodeType": "FunctionCallOptions",
+ "options": [
+ {
+ "argumentTypes": null,
+ "hexValue": "34303030",
+ "id": 1695,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "31092:4:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4000_by_1",
+ "typeString": "int_const 4000"
+ },
+ "value": "4000"
+ }
+ ],
+ "src": "31055:43:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_barestaticcall_view$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$gas",
+ "typeString": "function (bytes memory) view returns (bool,bytes memory)"
+ }
+ },
+ "id": 1698,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "31055:49:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$",
+ "typeString": "tuple(bool,bytes memory)"
+ }
+ },
+ "nodeType": "VariableDeclarationStatement",
+ "src": "31013:91:0"
+ },
+ {
+ "condition": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 1705,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 1700,
+ "name": "success",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1687,
+ "src": "31121:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 1704,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 1701,
+ "name": "returnData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1689,
+ "src": "31132:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ },
+ "id": 1702,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "length",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "31132:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "==",
+ "rightExpression": {
+ "argumentTypes": null,
+ "hexValue": "3332",
+ "id": 1703,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "31153:2:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_32_by_1",
+ "typeString": "int_const 32"
+ },
+ "value": "32"
+ },
+ "src": "31132:23:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "31121:34:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "falseBody": null,
+ "id": 1715,
+ "nodeType": "IfStatement",
+ "src": "31117:104:0",
+ "trueBody": {
+ "id": 1714,
+ "nodeType": "Block",
+ "src": "31157:64:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1708,
+ "name": "returnData",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1689,
+ "src": "31190:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "id": 1710,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "31203:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_bool_$",
+ "typeString": "type(bool)"
+ },
+ "typeName": {
+ "id": 1709,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "31203:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ }
+ ],
+ "id": 1711,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "31202:6:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_bool_$",
+ "typeString": "type(bool)"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bytes_memory_ptr",
+ "typeString": "bytes memory"
+ },
+ {
+ "typeIdentifier": "t_type$_t_bool_$",
+ "typeString": "type(bool)"
+ }
+ ],
+ "expression": {
+ "argumentTypes": null,
+ "id": 1706,
+ "name": "abi",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -1,
+ "src": "31179:3:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_abi",
+ "typeString": "abi"
+ }
+ },
+ "id": 1707,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "memberName": "decode",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "31179:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_abidecode_pure$__$returns$__$",
+ "typeString": "function () pure"
+ }
+ },
+ "id": 1712,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "31179:30:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "functionReturnParameters": 1678,
+ "id": 1713,
+ "nodeType": "Return",
+ "src": "31172:37:0"
+ }
+ ]
+ }
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "hexValue": "66616c7365",
+ "id": 1716,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "31240:5:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "false"
+ },
+ "functionReturnParameters": 1678,
+ "id": 1717,
+ "nodeType": "Return",
+ "src": "31233:12:0"
+ }
+ ]
+ },
+ "documentation": null,
+ "id": 1719,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "isV28OrHigherConverter",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1675,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1674,
+ "mutability": "mutable",
+ "name": "_converter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1719,
+ "src": "30865:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 1673,
+ "name": "IConverter",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 13340,
+ "src": "30865:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IConverter_$13340",
+ "typeString": "contract IConverter"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "30864:23:0"
+ },
+ "returnParameters": {
+ "id": 1678,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1677,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1719,
+ "src": "30911:4:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 1676,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "30911:4:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "30910:6:0"
+ },
+ "scope": 1976,
+ "src": "30833:420:0",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "internal"
+ },
+ {
+ "body": {
+ "id": 1739,
+ "nodeType": "Block",
+ "src": "31432:57:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "components": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1733,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1723,
+ "src": "31462:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1734,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1725,
+ "src": "31469:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1732,
+ "name": "rateByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 462,
+ "src": "31451:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_view$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256) view returns (uint256)"
+ }
+ },
+ "id": 1735,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "31451:26:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1736,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "31479:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "id": 1737,
+ "isConstant": false,
+ "isInlineArray": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "nodeType": "TupleExpression",
+ "src": "31450:31:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$_t_uint256_$_t_rational_0_by_1_$",
+ "typeString": "tuple(uint256,int_const 0)"
+ }
+ },
+ "functionReturnParameters": 1731,
+ "id": 1738,
+ "nodeType": "Return",
+ "src": "31443:38:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1720,
+ "nodeType": "StructuredDocumentation",
+ "src": "31261:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "0c8496cc",
+ "id": 1740,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "getReturnByPath",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1726,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1723,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1740,
+ "src": "31352:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1721,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "31352:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1722,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "31352:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1725,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1740,
+ "src": "31376:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1724,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31376:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "31351:41:0"
+ },
+ "returnParameters": {
+ "id": 1731,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1728,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1740,
+ "src": "31414:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1727,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31414:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1730,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1740,
+ "src": "31423:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1729,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31423:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "31413:18:0"
+ },
+ "scope": 1976,
+ "src": "31327:162:0",
+ "stateMutability": "view",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 1768,
+ "nodeType": "Block",
+ "src": "31674:94:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1754,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1744,
+ "src": "31706:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1755,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1746,
+ "src": "31713:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1756,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1748,
+ "src": "31722:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1759,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "31742:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1758,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "31734:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1757,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "31734:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1760,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "31734:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1763,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "31754:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1762,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "31746:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1761,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "31746:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1764,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "31746:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1765,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "31758:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1753,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "31692:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 1766,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "31692:68:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 1752,
+ "id": 1767,
+ "nodeType": "Return",
+ "src": "31685:75:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1741,
+ "nodeType": "StructuredDocumentation",
+ "src": "31497:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "f3898a97",
+ "id": 1769,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "convert",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1749,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1744,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1769,
+ "src": "31580:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1742,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "31580:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1743,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "31580:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1746,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1769,
+ "src": "31604:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1745,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31604:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1748,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1769,
+ "src": "31621:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1747,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31621:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "31579:61:0"
+ },
+ "returnParameters": {
+ "id": 1752,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1751,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1769,
+ "src": "31665:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1750,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31665:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "31664:9:0"
+ },
+ "scope": 1976,
+ "src": "31563:205:0",
+ "stateMutability": "payable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 1798,
+ "nodeType": "Block",
+ "src": "32088:113:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1787,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1773,
+ "src": "32120:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1788,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1775,
+ "src": "32127:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1789,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1777,
+ "src": "32136:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1792,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "32156:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1791,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "32148:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1790,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "32148:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1793,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "32148:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1794,
+ "name": "_affiliateAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1779,
+ "src": "32160:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1795,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1781,
+ "src": "32179:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1786,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "32106:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 1796,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "32106:87:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 1785,
+ "id": 1797,
+ "nodeType": "Return",
+ "src": "32099:94:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1770,
+ "nodeType": "StructuredDocumentation",
+ "src": "31776:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "569706eb",
+ "id": 1799,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "convert2",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1782,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1773,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1799,
+ "src": "31870:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1771,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "31870:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1772,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "31870:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1775,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1799,
+ "src": "31903:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1774,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31903:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1777,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1799,
+ "src": "31929:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1776,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31929:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1779,
+ "mutability": "mutable",
+ "name": "_affiliateAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1799,
+ "src": "31958:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 1778,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "31958:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1781,
+ "mutability": "mutable",
+ "name": "_affiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1799,
+ "src": "31994:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1780,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "31994:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "31859:163:0"
+ },
+ "returnParameters": {
+ "id": 1785,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1784,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1799,
+ "src": "32074:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1783,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32074:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "32073:9:0"
+ },
+ "scope": 1976,
+ "src": "31842:359:0",
+ "stateMutability": "payable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 1826,
+ "nodeType": "Block",
+ "src": "32419:96:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1815,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1803,
+ "src": "32451:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1816,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1805,
+ "src": "32458:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1817,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1807,
+ "src": "32467:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1818,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1809,
+ "src": "32479:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1821,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "32501:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1820,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "32493:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1819,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "32493:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1822,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "32493:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1823,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "32505:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1814,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "32437:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 1824,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "32437:70:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 1813,
+ "id": 1825,
+ "nodeType": "Return",
+ "src": "32430:77:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1800,
+ "nodeType": "StructuredDocumentation",
+ "src": "32209:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "c98fefed",
+ "id": 1827,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "convertFor",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1810,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1803,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1827,
+ "src": "32295:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1801,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "32295:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1802,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "32295:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1805,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1827,
+ "src": "32319:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1804,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32319:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1807,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1827,
+ "src": "32336:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1806,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32336:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1809,
+ "mutability": "mutable",
+ "name": "_beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1827,
+ "src": "32356:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 1808,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "32356:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "32294:91:0"
+ },
+ "returnParameters": {
+ "id": 1813,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1812,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1827,
+ "src": "32410:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1811,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32410:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "32409:9:0"
+ },
+ "scope": 1976,
+ "src": "32275:240:0",
+ "stateMutability": "payable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 1858,
+ "nodeType": "Block",
+ "src": "32914:115:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1850,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1831,
+ "src": "32946:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1851,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1833,
+ "src": "32953:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1852,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1835,
+ "src": "32962:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1853,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1837,
+ "src": "32974:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1854,
+ "name": "_affiliateAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1839,
+ "src": "32988:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1855,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1841,
+ "src": "33007:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1849,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "32932:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 1856,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "32932:89:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 1848,
+ "id": 1857,
+ "nodeType": "Return",
+ "src": "32925:96:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1828,
+ "nodeType": "StructuredDocumentation",
+ "src": "32523:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "ab6214ce",
+ "id": 1859,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1844,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1835,
+ "src": "32870:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 1845,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 1843,
+ "name": "greaterThanZero",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22595,
+ "src": "32854:15:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$_t_uint256_$",
+ "typeString": "modifier (uint256)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "32854:27:0"
+ }
+ ],
+ "name": "convertFor2",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1842,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1831,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1859,
+ "src": "32620:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1829,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "32620:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1830,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "32620:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1833,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1859,
+ "src": "32653:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1832,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32653:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1835,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1859,
+ "src": "32679:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1834,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32679:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1837,
+ "mutability": "mutable",
+ "name": "_beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1859,
+ "src": "32708:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 1836,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "32708:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1839,
+ "mutability": "mutable",
+ "name": "_affiliateAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1859,
+ "src": "32747:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 1838,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "32747:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1841,
+ "mutability": "mutable",
+ "name": "_affiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1859,
+ "src": "32783:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1840,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32783:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "32609:202:0"
+ },
+ "returnParameters": {
+ "id": 1848,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1847,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1859,
+ "src": "32900:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1846,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "32900:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "32899:9:0"
+ },
+ "scope": 1976,
+ "src": "32589:440:0",
+ "stateMutability": "payable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 1887,
+ "nodeType": "Block",
+ "src": "33214:94:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1873,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1863,
+ "src": "33246:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1874,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1865,
+ "src": "33253:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1875,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1867,
+ "src": "33262:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1878,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33282:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1877,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "33274:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1876,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "33274:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1879,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33274:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1882,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33294:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1881,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "33286:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1880,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "33286:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1883,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33286:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1884,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33298:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1872,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "33232:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 1885,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33232:68:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 1871,
+ "id": 1886,
+ "nodeType": "Return",
+ "src": "33225:75:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1860,
+ "nodeType": "StructuredDocumentation",
+ "src": "33037:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "c7ba24bc",
+ "id": 1888,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "claimAndConvert",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1868,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1863,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1888,
+ "src": "33128:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1861,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "33128:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1862,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "33128:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1865,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1888,
+ "src": "33152:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1864,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33152:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1867,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1888,
+ "src": "33169:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1866,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33169:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "33127:61:0"
+ },
+ "returnParameters": {
+ "id": 1871,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1870,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1888,
+ "src": "33205:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1869,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33205:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "33204:9:0"
+ },
+ "scope": 1976,
+ "src": "33103:205:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 1917,
+ "nodeType": "Block",
+ "src": "33619:113:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1906,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1892,
+ "src": "33651:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1907,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1894,
+ "src": "33658:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1908,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1896,
+ "src": "33667:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1911,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "33687:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1910,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "33679:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1909,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "33679:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1912,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33679:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1913,
+ "name": "_affiliateAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1898,
+ "src": "33691:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1914,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1900,
+ "src": "33710:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1905,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "33637:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 1915,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33637:87:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 1904,
+ "id": 1916,
+ "nodeType": "Return",
+ "src": "33630:94:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1889,
+ "nodeType": "StructuredDocumentation",
+ "src": "33316:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "e57738e5",
+ "id": 1918,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "claimAndConvert2",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1901,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1892,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1918,
+ "src": "33418:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1890,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "33418:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1891,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "33418:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1894,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1918,
+ "src": "33451:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1893,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33451:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1896,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1918,
+ "src": "33477:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1895,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33477:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1898,
+ "mutability": "mutable",
+ "name": "_affiliateAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1918,
+ "src": "33506:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 1897,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "33506:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1900,
+ "mutability": "mutable",
+ "name": "_affiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1918,
+ "src": "33542:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1899,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33542:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "33407:163:0"
+ },
+ "returnParameters": {
+ "id": 1904,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1903,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1918,
+ "src": "33605:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1902,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33605:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "33604:9:0"
+ },
+ "scope": 1976,
+ "src": "33382:350:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 1945,
+ "nodeType": "Block",
+ "src": "33950:96:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1934,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1922,
+ "src": "33982:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1935,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1924,
+ "src": "33989:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1936,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1926,
+ "src": "33998:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1937,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1928,
+ "src": "34010:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1940,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "34032:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1939,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "34024:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 1938,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "34024:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 1941,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "34024:10:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "30",
+ "id": 1942,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "34036:1:0",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ },
+ "value": "0"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_rational_0_by_1",
+ "typeString": "int_const 0"
+ }
+ ],
+ "id": 1933,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "33968:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 1943,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "33968:70:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 1932,
+ "id": 1944,
+ "nodeType": "Return",
+ "src": "33961:77:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1919,
+ "nodeType": "StructuredDocumentation",
+ "src": "33740:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "b1e9932b",
+ "id": 1946,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "claimAndConvertFor",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1929,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1922,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1946,
+ "src": "33834:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1920,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "33834:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1921,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "33834:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1924,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1946,
+ "src": "33858:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1923,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33858:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1926,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1946,
+ "src": "33875:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1925,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33875:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1928,
+ "mutability": "mutable",
+ "name": "_beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1946,
+ "src": "33895:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 1927,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "33895:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "33833:91:0"
+ },
+ "returnParameters": {
+ "id": 1932,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1931,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1946,
+ "src": "33941:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1930,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "33941:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "33940:9:0"
+ },
+ "scope": 1976,
+ "src": "33806:240:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ },
+ {
+ "body": {
+ "id": 1974,
+ "nodeType": "Block",
+ "src": "34399:115:0",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 1966,
+ "name": "_path",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1950,
+ "src": "34431:5:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1967,
+ "name": "_amount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1952,
+ "src": "34438:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1968,
+ "name": "_minReturn",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1954,
+ "src": "34447:10:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1969,
+ "name": "_beneficiary",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1956,
+ "src": "34459:12:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1970,
+ "name": "_affiliateAccount",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1958,
+ "src": "34473:17:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "id": 1971,
+ "name": "_affiliateFee",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 1960,
+ "src": "34492:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[] memory"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ ],
+ "id": 1965,
+ "name": "convertByPath",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 598,
+ "src": "34417:13:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_internal_nonpayable$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_payable_$_t_address_$_t_uint256_$returns$_t_uint256_$",
+ "typeString": "function (address[] memory,uint256,uint256,address payable,address,uint256) returns (uint256)"
+ }
+ },
+ "id": 1972,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "34417:89:0",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "functionReturnParameters": 1964,
+ "id": 1973,
+ "nodeType": "Return",
+ "src": "34410:96:0"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 1947,
+ "nodeType": "StructuredDocumentation",
+ "src": "34054:60:0",
+ "text": " @dev deprecated, backward compatibility"
+ },
+ "functionSelector": "2978c10e",
+ "id": 1975,
+ "implemented": true,
+ "kind": "function",
+ "modifiers": [],
+ "name": "claimAndConvertFor2",
+ "nodeType": "FunctionDefinition",
+ "overrides": null,
+ "parameters": {
+ "id": 1961,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1950,
+ "mutability": "mutable",
+ "name": "_path",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1975,
+ "src": "34159:22:0",
+ "stateVariable": false,
+ "storageLocation": "memory",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
+ "typeString": "address[]"
+ },
+ "typeName": {
+ "baseType": {
+ "id": 1948,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "34159:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "id": 1949,
+ "length": null,
+ "nodeType": "ArrayTypeName",
+ "src": "34159:9:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
+ "typeString": "address[]"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1952,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1975,
+ "src": "34192:15:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1951,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "34192:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1954,
+ "mutability": "mutable",
+ "name": "_minReturn",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1975,
+ "src": "34218:18:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1953,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "34218:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1956,
+ "mutability": "mutable",
+ "name": "_beneficiary",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1975,
+ "src": "34247:28:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ },
+ "typeName": {
+ "id": 1955,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "34247:15:0",
+ "stateMutability": "payable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address_payable",
+ "typeString": "address payable"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1958,
+ "mutability": "mutable",
+ "name": "_affiliateAccount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1975,
+ "src": "34286:25:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 1957,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "34286:7:0",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 1960,
+ "mutability": "mutable",
+ "name": "_affiliateFee",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1975,
+ "src": "34322:21:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1959,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "34322:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "34148:202:0"
+ },
+ "returnParameters": {
+ "id": 1964,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 1963,
+ "mutability": "mutable",
+ "name": "",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 1975,
+ "src": "34385:7:0",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 1962,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "34385:7:0",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "34384:9:0"
+ },
+ "scope": 1976,
+ "src": "34120:394:0",
+ "stateMutability": "nonpayable",
+ "virtual": false,
+ "visibility": "public"
+ }
+ ],
+ "scope": 1977,
+ "src": "1956:32561:0"
+ }
+ ],
+ "src": "52:34467:0"
+ },
+ "compiler": {
+ "name": "solc",
+ "version": "0.6.12+commit.27d51765.Emscripten.clang"
+ },
+ "networks": {
+ "42": {
+ "events": {
+ "0x7154b38b5dd31bb3122436a96d4e09aba5b323ae1fd580025fab55074334c095": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "contract IConverterAnchor",
+ "name": "_smartToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_fromToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_toToken",
+ "type": "address"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_fromAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_toAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "address",
+ "name": "_trader",
+ "type": "address"
+ }
+ ],
+ "name": "Conversion",
+ "type": "event"
+ },
+ "0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_prevOwner",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_newOwner",
+ "type": "address"
+ }
+ ],
+ "name": "OwnerUpdate",
+ "type": "event"
+ }
+ },
+ "links": {},
+ "address": "0xc7dFBf7C3865831728bF0c5b1B662d4E11909005",
+ "transactionHash": "0x47d9f1de607c670ebe9de58d95782b46ab64eacf5e2cabc0c71d8269c20be48a"
+ },
+ "8995": {
+ "events": {
+ "0x7154b38b5dd31bb3122436a96d4e09aba5b323ae1fd580025fab55074334c095": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "contract IConverterAnchor",
+ "name": "_smartToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_fromToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_toToken",
+ "type": "address"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_fromAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_toAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "address",
+ "name": "_trader",
+ "type": "address"
+ }
+ ],
+ "name": "Conversion",
+ "type": "event"
+ },
+ "0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_prevOwner",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_newOwner",
+ "type": "address"
+ }
+ ],
+ "name": "OwnerUpdate",
+ "type": "event"
+ }
+ },
+ "links": {},
+ "address": "0xc7dFBf7C3865831728bF0c5b1B662d4E11909005",
+ "transactionHash": "0x47d9f1de607c670ebe9de58d95782b46ab64eacf5e2cabc0c71d8269c20be48a"
+ },
+ "1604964387852": {
+ "events": {
+ "0x7154b38b5dd31bb3122436a96d4e09aba5b323ae1fd580025fab55074334c095": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "contract IConverterAnchor",
+ "name": "_smartToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_fromToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_toToken",
+ "type": "address"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_fromAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_toAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "address",
+ "name": "_trader",
+ "type": "address"
+ }
+ ],
+ "name": "Conversion",
+ "type": "event"
+ },
+ "0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_prevOwner",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_newOwner",
+ "type": "address"
+ }
+ ],
+ "name": "OwnerUpdate",
+ "type": "event"
+ }
+ },
+ "links": {},
+ "address": "0x79Df6FCbe685456c0B6c2142d096cf28b107D5E2",
+ "transactionHash": "0x9f34297d1c73a34acf54f0235b7d59cce9f7f1755c43516fd4551cc8795f0eb8"
+ },
+ "1604964469407": {
+ "events": {
+ "0x7154b38b5dd31bb3122436a96d4e09aba5b323ae1fd580025fab55074334c095": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "contract IConverterAnchor",
+ "name": "_smartToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_fromToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_toToken",
+ "type": "address"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_fromAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_toAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "address",
+ "name": "_trader",
+ "type": "address"
+ }
+ ],
+ "name": "Conversion",
+ "type": "event"
+ },
+ "0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_prevOwner",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_newOwner",
+ "type": "address"
+ }
+ ],
+ "name": "OwnerUpdate",
+ "type": "event"
+ }
+ },
+ "links": {},
+ "address": "0x1C591A1950ca22c368d79c1cc9648cAc7426797E",
+ "transactionHash": "0x03a83b3e4affee17bffb32d1a3c7f576607a8de5e32e86b0101d72b7d78f860a"
+ },
+ "1604965528035": {
+ "events": {
+ "0x7154b38b5dd31bb3122436a96d4e09aba5b323ae1fd580025fab55074334c095": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "contract IConverterAnchor",
+ "name": "_smartToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_fromToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_toToken",
+ "type": "address"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_fromAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_toAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "address",
+ "name": "_trader",
+ "type": "address"
+ }
+ ],
+ "name": "Conversion",
+ "type": "event"
+ },
+ "0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_prevOwner",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_newOwner",
+ "type": "address"
+ }
+ ],
+ "name": "OwnerUpdate",
+ "type": "event"
+ }
+ },
+ "links": {},
+ "address": "0xa187689A9912C7422097922cF8D16601A0284422",
+ "transactionHash": "0xb3f6d67e818f1f33cb382fd41771ff17cd2707c790aedc9d32245608868459e7"
+ },
+ "1604965645554": {
+ "events": {
+ "0x7154b38b5dd31bb3122436a96d4e09aba5b323ae1fd580025fab55074334c095": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "contract IConverterAnchor",
+ "name": "_smartToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_fromToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_toToken",
+ "type": "address"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_fromAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_toAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "address",
+ "name": "_trader",
+ "type": "address"
+ }
+ ],
+ "name": "Conversion",
+ "type": "event"
+ },
+ "0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_prevOwner",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_newOwner",
+ "type": "address"
+ }
+ ],
+ "name": "OwnerUpdate",
+ "type": "event"
+ }
+ },
+ "links": {},
+ "address": "0x453FB4036a75fAA2e9373E475b22Ac1a5006A855",
+ "transactionHash": "0xa320f62f3a0a7125f7a692d182a2a43c7f4824510771365e6116c1208a55fff4"
+ },
+ "1604965679541": {
+ "events": {
+ "0x7154b38b5dd31bb3122436a96d4e09aba5b323ae1fd580025fab55074334c095": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "contract IConverterAnchor",
+ "name": "_smartToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_fromToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_toToken",
+ "type": "address"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_fromAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_toAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "address",
+ "name": "_trader",
+ "type": "address"
+ }
+ ],
+ "name": "Conversion",
+ "type": "event"
+ },
+ "0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_prevOwner",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_newOwner",
+ "type": "address"
+ }
+ ],
+ "name": "OwnerUpdate",
+ "type": "event"
+ }
+ },
+ "links": {},
+ "address": "0x4dF29e19Ee922f24355217E0E99ccC7E0428e047",
+ "transactionHash": "0xcc96660274b6be9da1e54c81047b4d359ca98f5132c7854c142d0c7b94d8012a"
+ },
+ "1604965719492": {
+ "events": {
+ "0x7154b38b5dd31bb3122436a96d4e09aba5b323ae1fd580025fab55074334c095": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "contract IConverterAnchor",
+ "name": "_smartToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_fromToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_toToken",
+ "type": "address"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_fromAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_toAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "address",
+ "name": "_trader",
+ "type": "address"
+ }
+ ],
+ "name": "Conversion",
+ "type": "event"
+ },
+ "0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_prevOwner",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_newOwner",
+ "type": "address"
+ }
+ ],
+ "name": "OwnerUpdate",
+ "type": "event"
+ }
+ },
+ "links": {},
+ "address": "0x82E0022A199255785123B8AEAa10913fc88cB97f",
+ "transactionHash": "0x17803233e04d31d33dca399b94cdc9e717b1d492727d33c7f15e4e550e6873f7"
+ },
+ "1604965760834": {
+ "events": {
+ "0x7154b38b5dd31bb3122436a96d4e09aba5b323ae1fd580025fab55074334c095": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "contract IConverterAnchor",
+ "name": "_smartToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_fromToken",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "contract IERC20Token",
+ "name": "_toToken",
+ "type": "address"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_fromAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_toAmount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "address",
+ "name": "_trader",
+ "type": "address"
+ }
+ ],
+ "name": "Conversion",
+ "type": "event"
+ },
+ "0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_prevOwner",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_newOwner",
+ "type": "address"
+ }
+ ],
+ "name": "OwnerUpdate",
+ "type": "event"
+ }
+ },
+ "links": {},
+ "address": "0x965e4A39955c8c4EF02366420d35F82aB56669b7",
+ "transactionHash": "0x595c8ba6fe67726990ab55caf71047b0f0cf5821870849a67b2bc5c17d9a8413"
+ }
+ },
+ "schemaVersion": "3.2.3",
+ "updatedAt": "2020-11-10T14:20:44.742Z",
+ "networkType": "ethereum",
+ "devdoc": {
+ "details": "The BancorNetwork contract is the main entry point for Bancor token conversions. It also allows for the conversion of any token in the Bancor Network to any other token in a single transaction by providing a conversion path. A note on Conversion Path: Conversion path is a data structure that is used when converting a token to another token in the Bancor Network, when the conversion cannot necessarily be done by a single converter and might require multiple 'hops'. The path defines which converters should be used and what kind of conversion should be done in each step. The path format doesn't include complex structure; instead, it is represented by a single array in which each 'hop' is represented by a 2-tuple - converter anchor & target token. In addition, the first element is always the source token. The converter anchor is only used as a pointer to a converter (since converter addresses are more likely to change as opposed to anchor addresses). Format: [source token, converter anchor, target token, converter anchor, target token...]",
+ "events": {
+ "Conversion(address,address,address,uint256,uint256,address)": {
+ "details": "triggered when a conversion between two tokens occurs",
+ "params": {
+ "_fromAmount": "amount converted, in the source token",
+ "_fromToken": "source ERC20 token",
+ "_smartToken": "anchor governed by the converter",
+ "_toAmount": "amount returned, minus conversion fee",
+ "_toToken": "target ERC20 token",
+ "_trader": "wallet that initiated the trade"
+ }
+ }
+ },
+ "kind": "dev",
+ "methods": {
+ "acceptOwnership()": {
+ "details": "used by a new owner to accept an ownership transfer"
+ },
+ "claimAndConvert(address[],uint256,uint256)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "claimAndConvert2(address[],uint256,uint256,address,uint256)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "claimAndConvertFor(address[],uint256,uint256,address)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "claimAndConvertFor2(address[],uint256,uint256,address,address,uint256)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "completeXConversion(address[],address,uint256,uint256,address)": {
+ "details": "allows a user to convert a token that was sent from another blockchain into any other token on the BancorNetwork ideally this transaction is created before the previous conversion is even complete, so so the input amount isn't known at that point - the amount is actually take from the BancorX contract directly by specifying the conversion id",
+ "params": {
+ "_bancorX": "address of the BancorX contract for the source token",
+ "_beneficiary": "wallet to receive the conversion result",
+ "_conversionId": "pre-determined unique (if non zero) id which refers to this conversion",
+ "_minReturn": "if the conversion results in an amount smaller than the minimum return - it is cancelled, must be nonzero",
+ "_path": "conversion path"
+ },
+ "returns": {
+ "_0": "amount of tokens received from the conversion"
+ }
+ },
+ "constructor": {
+ "details": "initializes a new BancorNetwork instance",
+ "params": {
+ "_registry": "address of a contract registry contract"
+ }
+ },
+ "conversionPath(address,address)": {
+ "details": "returns the conversion path between two tokens in the network note that this method is quite expensive in terms of gas and should generally be called off-chain",
+ "params": {
+ "_sourceToken": "source token address",
+ "_targetToken": "target token address"
+ },
+ "returns": {
+ "_0": "conversion path between the two tokens"
+ }
+ },
+ "convert(address[],uint256,uint256)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "convert2(address[],uint256,uint256,address,uint256)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "convertByPath(address[],uint256,uint256,address,address,uint256)": {
+ "details": "converts the token to any other token in the bancor network by following a predefined conversion path and transfers the result tokens to a target account affiliate account/fee can also be passed in to receive a conversion fee (on top of the liquidity provider fees) note that the network should already have been given allowance of the source token (if not ETH)",
+ "params": {
+ "_affiliateAccount": "wallet address to receive the affiliate fee or 0x0 to disable affiliate fee",
+ "_affiliateFee": "affiliate fee in PPM or 0 to disable affiliate fee",
+ "_amount": "amount to convert from, in the source token",
+ "_beneficiary": "account that will receive the conversion result or 0x0 to send the result to the sender account",
+ "_minReturn": "if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero",
+ "_path": "conversion path, see conversion path format above"
+ },
+ "returns": {
+ "_0": "amount of tokens received from the conversion"
+ }
+ },
+ "convertFor(address[],uint256,uint256,address)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "convertFor2(address[],uint256,uint256,address,address,uint256)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "getReturnByPath(address[],uint256)": {
+ "details": "deprecated, backward compatibility"
+ },
+ "rateByPath(address[],uint256)": {
+ "details": "returns the expected target amount of converting a given amount on a given path note that there is no support for circular paths",
+ "params": {
+ "_amount": "amount of _path[0] tokens received from the sender",
+ "_path": "conversion path (see conversion path format above)"
+ },
+ "returns": {
+ "_0": "expected target amount"
+ }
+ },
+ "registerEtherToken(address,bool)": {
+ "details": "allows the owner to register/unregister ether tokens",
+ "params": {
+ "_register": "true to register, false to unregister",
+ "_token": "ether token contract address"
+ }
+ },
+ "restoreRegistry()": {
+ "details": "restores the previous contract-registry"
+ },
+ "restrictRegistryUpdate(bool)": {
+ "details": "restricts the permission to update the contract-registry",
+ "params": {
+ "_onlyOwnerCanUpdateRegistry": "indicates whether or not permission is restricted to owner only"
+ }
+ },
+ "setMaxAffiliateFee(uint256)": {
+ "details": "allows the owner to update the maximum affiliate-fee",
+ "params": {
+ "_maxAffiliateFee": "maximum affiliate-fee"
+ }
+ },
+ "transferOwnership(address)": {
+ "details": "allows transferring the contract ownership the new owner still needs to accept the transfer can only be called by the contract owner",
+ "params": {
+ "_newOwner": "new contract owner"
+ }
+ },
+ "updateRegistry()": {
+ "details": "updates to the new contract-registry"
+ },
+ "withdrawTokens(address,address,uint256)": {
+ "details": "withdraws tokens held by the contract and sends them to an account can only be called by the owner",
+ "params": {
+ "_amount": "amount to withdraw",
+ "_to": "account to receive the new amount",
+ "_token": "ERC20 token contract address"
+ }
+ },
+ "xConvert(address[],uint256,uint256,bytes32,bytes32,uint256)": {
+ "details": "converts any other token to BNT in the bancor network by following a predefined conversion path and transfers the result to an account on a different blockchain note that the network should already have been given allowance of the source token (if not ETH)",
+ "params": {
+ "_amount": "amount to convert from, in the source token",
+ "_conversionId": "pre-determined unique (if non zero) id which refers to this transaction",
+ "_minReturn": "if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero",
+ "_path": "conversion path, see conversion path format above",
+ "_targetAccount": "address/account on the target blockchain to send the BNT to",
+ "_targetBlockchain": "blockchain BNT will be issued on"
+ },
+ "returns": {
+ "_0": "the amount of BNT received from this conversion"
+ }
+ },
+ "xConvert2(address[],uint256,uint256,bytes32,bytes32,uint256,address,uint256)": {
+ "details": "converts any other token to BNT in the bancor network by following a predefined conversion path and transfers the result to an account on a different blockchain note that the network should already have been given allowance of the source token (if not ETH)",
+ "params": {
+ "_affiliateAccount": "affiliate account",
+ "_affiliateFee": "affiliate fee in PPM",
+ "_amount": "amount to convert from, in the source token",
+ "_conversionId": "pre-determined unique (if non zero) id which refers to this transaction",
+ "_minReturn": "if the conversion results in an amount smaller than the minimum return - it is cancelled, must be greater than zero",
+ "_path": "conversion path, see conversion path format above",
+ "_targetAccount": "address/account on the target blockchain to send the BNT to",
+ "_targetBlockchain": "blockchain BNT will be issued on"
+ },
+ "returns": {
+ "_0": "the amount of BNT received from this conversion"
+ }
+ }
+ },
+ "version": 1
+ },
+ "userdoc": {
+ "kind": "user",
+ "methods": {},
+ "version": 1
+ }
+}
\ No newline at end of file
diff --git a/apps/cic-eth/tests/testdata/bancor/BancorX.json b/apps/cic-eth/tests/testdata/bancor/BancorX.json
new file mode 100644
index 00000000..9568edb9
--- /dev/null
+++ b/apps/cic-eth/tests/testdata/bancor/BancorX.json
@@ -0,0 +1,24111 @@
+{
+ "contractName": "BancorX",
+ "abi": [
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_maxLockLimit",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_maxReleaseLimit",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_minLimit",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_limitIncPerBlock",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint8",
+ "name": "_minRequiredReports",
+ "type": "uint8"
+ },
+ {
+ "internalType": "contract IContractRegistry",
+ "name": "_registry",
+ "type": "address"
+ },
+ {
+ "internalType": "contract IERC20Token",
+ "name": "_token",
+ "type": "address"
+ }
+ ],
+ "stateMutability": "nonpayable",
+ "type": "constructor"
+ },
+ {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_prevOwner",
+ "type": "address"
+ },
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_newOwner",
+ "type": "address"
+ }
+ ],
+ "name": "OwnerUpdate",
+ "type": "event"
+ },
+ {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_from",
+ "type": "address"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "TokensLock",
+ "type": "event"
+ },
+ {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_to",
+ "type": "address"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "TokensRelease",
+ "type": "event"
+ },
+ {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_reporter",
+ "type": "address"
+ },
+ {
+ "indexed": false,
+ "internalType": "bytes32",
+ "name": "_fromBlockchain",
+ "type": "bytes32"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_txId",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "address",
+ "name": "_to",
+ "type": "address"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_xTransferId",
+ "type": "uint256"
+ }
+ ],
+ "name": "TxReport",
+ "type": "event"
+ },
+ {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": true,
+ "internalType": "address",
+ "name": "_from",
+ "type": "address"
+ },
+ {
+ "indexed": false,
+ "internalType": "bytes32",
+ "name": "_toBlockchain",
+ "type": "bytes32"
+ },
+ {
+ "indexed": true,
+ "internalType": "bytes32",
+ "name": "_to",
+ "type": "bytes32"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_id",
+ "type": "uint256"
+ }
+ ],
+ "name": "XTransfer",
+ "type": "event"
+ },
+ {
+ "anonymous": false,
+ "inputs": [
+ {
+ "indexed": false,
+ "internalType": "address",
+ "name": "_to",
+ "type": "address"
+ },
+ {
+ "indexed": false,
+ "internalType": "uint256",
+ "name": "_id",
+ "type": "uint256"
+ }
+ ],
+ "name": "XTransferComplete",
+ "type": "event"
+ },
+ {
+ "inputs": [],
+ "name": "acceptOwnership",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "limitIncPerBlock",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "maxLockLimit",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "maxReleaseLimit",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "minLimit",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "minRequiredReports",
+ "outputs": [
+ {
+ "internalType": "uint8",
+ "name": "",
+ "type": "uint8"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "newOwner",
+ "outputs": [
+ {
+ "internalType": "address",
+ "name": "",
+ "type": "address"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "onlyOwnerCanUpdateRegistry",
+ "outputs": [
+ {
+ "internalType": "bool",
+ "name": "",
+ "type": "bool"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "owner",
+ "outputs": [
+ {
+ "internalType": "address",
+ "name": "",
+ "type": "address"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "prevLockBlockNumber",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "prevLockLimit",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "prevRegistry",
+ "outputs": [
+ {
+ "internalType": "contract IContractRegistry",
+ "name": "",
+ "type": "address"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "prevReleaseBlockNumber",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "prevReleaseLimit",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "registry",
+ "outputs": [
+ {
+ "internalType": "contract IContractRegistry",
+ "name": "",
+ "type": "address"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ },
+ {
+ "internalType": "address",
+ "name": "",
+ "type": "address"
+ }
+ ],
+ "name": "reportedTxs",
+ "outputs": [
+ {
+ "internalType": "bool",
+ "name": "",
+ "type": "bool"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address",
+ "name": "",
+ "type": "address"
+ }
+ ],
+ "name": "reporters",
+ "outputs": [
+ {
+ "internalType": "bool",
+ "name": "",
+ "type": "bool"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "reportingEnabled",
+ "outputs": [
+ {
+ "internalType": "bool",
+ "name": "",
+ "type": "bool"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "restoreRegistry",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "bool",
+ "name": "_onlyOwnerCanUpdateRegistry",
+ "type": "bool"
+ }
+ ],
+ "name": "restrictRegistryUpdate",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "token",
+ "outputs": [
+ {
+ "internalType": "contract IERC20Token",
+ "name": "",
+ "type": "address"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "name": "transactionIds",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "name": "transactions",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "amount",
+ "type": "uint256"
+ },
+ {
+ "internalType": "bytes32",
+ "name": "fromBlockchain",
+ "type": "bytes32"
+ },
+ {
+ "internalType": "address",
+ "name": "to",
+ "type": "address"
+ },
+ {
+ "internalType": "uint8",
+ "name": "numOfReports",
+ "type": "uint8"
+ },
+ {
+ "internalType": "bool",
+ "name": "completed",
+ "type": "bool"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address",
+ "name": "_newOwner",
+ "type": "address"
+ }
+ ],
+ "name": "transferOwnership",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "updateRegistry",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "version",
+ "outputs": [
+ {
+ "internalType": "uint16",
+ "name": "",
+ "type": "uint16"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "contract IERC20Token",
+ "name": "_token",
+ "type": "address"
+ },
+ {
+ "internalType": "address",
+ "name": "_to",
+ "type": "address"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "withdrawTokens",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "xTransfersEnabled",
+ "outputs": [
+ {
+ "internalType": "bool",
+ "name": "",
+ "type": "bool"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_maxLockLimit",
+ "type": "uint256"
+ }
+ ],
+ "name": "setMaxLockLimit",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_maxReleaseLimit",
+ "type": "uint256"
+ }
+ ],
+ "name": "setMaxReleaseLimit",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_minLimit",
+ "type": "uint256"
+ }
+ ],
+ "name": "setMinLimit",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_limitIncPerBlock",
+ "type": "uint256"
+ }
+ ],
+ "name": "setLimitIncPerBlock",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint8",
+ "name": "_minRequiredReports",
+ "type": "uint8"
+ }
+ ],
+ "name": "setMinRequiredReports",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address",
+ "name": "_reporter",
+ "type": "address"
+ },
+ {
+ "internalType": "bool",
+ "name": "_active",
+ "type": "bool"
+ }
+ ],
+ "name": "setReporter",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "bool",
+ "name": "_enable",
+ "type": "bool"
+ }
+ ],
+ "name": "enableXTransfers",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "bool",
+ "name": "_enable",
+ "type": "bool"
+ }
+ ],
+ "name": "enableReporting",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address[]",
+ "name": "_reporters",
+ "type": "address[]"
+ }
+ ],
+ "name": "upgrade",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "bytes32",
+ "name": "_toBlockchain",
+ "type": "bytes32"
+ },
+ {
+ "internalType": "bytes32",
+ "name": "_to",
+ "type": "bytes32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_id",
+ "type": "uint256"
+ }
+ ],
+ "name": "xTransfer",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "bytes32",
+ "name": "_toBlockchain",
+ "type": "bytes32"
+ },
+ {
+ "internalType": "bytes32",
+ "name": "_to",
+ "type": "bytes32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ }
+ ],
+ "name": "xTransfer",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "bytes32",
+ "name": "_fromBlockchain",
+ "type": "bytes32"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_txId",
+ "type": "uint256"
+ },
+ {
+ "internalType": "address",
+ "name": "_to",
+ "type": "address"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_amount",
+ "type": "uint256"
+ },
+ {
+ "internalType": "uint256",
+ "name": "_xTransferId",
+ "type": "uint256"
+ }
+ ],
+ "name": "reportTx",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "uint256",
+ "name": "_xTransferId",
+ "type": "uint256"
+ },
+ {
+ "internalType": "address",
+ "name": "_for",
+ "type": "address"
+ }
+ ],
+ "name": "getXTransferAmount",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "getCurrentLockLimit",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "getCurrentReleaseLimit",
+ "outputs": [
+ {
+ "internalType": "uint256",
+ "name": "",
+ "type": "uint256"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ }
+ ],
+ "metadata": "{\"compiler\":{\"version\":\"0.6.12+commit.27d51765\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_maxLockLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_maxReleaseLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_minLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_limitIncPerBlock\",\"type\":\"uint256\"},{\"internalType\":\"uint8\",\"name\":\"_minRequiredReports\",\"type\":\"uint8\"},{\"internalType\":\"contract IContractRegistry\",\"name\":\"_registry\",\"type\":\"address\"},{\"internalType\":\"contract IERC20Token\",\"name\":\"_token\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"_prevOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"_newOwner\",\"type\":\"address\"}],\"name\":\"OwnerUpdate\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"TokensLock\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"TokensRelease\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"_reporter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"_fromBlockchain\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"_txId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"_xTransferId\",\"type\":\"uint256\"}],\"name\":\"TxReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"_toBlockchain\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"_to\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"_id\",\"type\":\"uint256\"}],\"name\":\"XTransfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"_id\",\"type\":\"uint256\"}],\"name\":\"XTransferComplete\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"_enable\",\"type\":\"bool\"}],\"name\":\"enableReporting\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"_enable\",\"type\":\"bool\"}],\"name\":\"enableXTransfers\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCurrentLockLimit\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCurrentReleaseLimit\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_xTransferId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"_for\",\"type\":\"address\"}],\"name\":\"getXTransferAmount\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"limitIncPerBlock\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"maxLockLimit\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"maxReleaseLimit\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minLimit\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minRequiredReports\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"newOwner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"onlyOwnerCanUpdateRegistry\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"prevLockBlockNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"prevLockLimit\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"prevRegistry\",\"outputs\":[{\"internalType\":\"contract IContractRegistry\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"prevReleaseBlockNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"prevReleaseLimit\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contract IContractRegistry\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_fromBlockchain\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_txId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_xTransferId\",\"type\":\"uint256\"}],\"name\":\"reportTx\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"reportedTxs\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"reporters\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"reportingEnabled\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"restoreRegistry\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"_onlyOwnerCanUpdateRegistry\",\"type\":\"bool\"}],\"name\":\"restrictRegistryUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_limitIncPerBlock\",\"type\":\"uint256\"}],\"name\":\"setLimitIncPerBlock\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_maxLockLimit\",\"type\":\"uint256\"}],\"name\":\"setMaxLockLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_maxReleaseLimit\",\"type\":\"uint256\"}],\"name\":\"setMaxReleaseLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_minLimit\",\"type\":\"uint256\"}],\"name\":\"setMinLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"_minRequiredReports\",\"type\":\"uint8\"}],\"name\":\"setMinRequiredReports\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_reporter\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"_active\",\"type\":\"bool\"}],\"name\":\"setReporter\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"token\",\"outputs\":[{\"internalType\":\"contract IERC20Token\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"transactionIds\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"transactions\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"fromBlockchain\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"numOfReports\",\"type\":\"uint8\"},{\"internalType\":\"bool\",\"name\":\"completed\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateRegistry\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_reporters\",\"type\":\"address[]\"}],\"name\":\"upgrade\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contract IERC20Token\",\"name\":\"_token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"withdrawTokens\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_toBlockchain\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"_to\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_id\",\"type\":\"uint256\"}],\"name\":\"xTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_toBlockchain\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"_to\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"xTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"xTransfersEnabled\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"details\":\"The BancorX contract allows cross chain token transfers. There are two processes that take place in the contract - - Initiate a cross chain transfer to a target blockchain (locks tokens from the caller account on Ethereum) - Report a cross chain transfer initiated on a source blockchain (releases tokens to an account on Ethereum) Reporting cross chain transfers works similar to standard multisig contracts, meaning that multiple callers are required to report a transfer before tokens are released to the target account.\",\"events\":{\"TokensLock(address,uint256)\":{\"details\":\"triggered when tokens are locked in smart contract\",\"params\":{\"_amount\":\"amount locked\",\"_from\":\"wallet address that the tokens are locked from\"}},\"TokensRelease(address,uint256)\":{\"details\":\"triggered when tokens are released by the smart contract\",\"params\":{\"_amount\":\"amount released\",\"_to\":\"wallet address that the tokens are released to\"}},\"TxReport(address,bytes32,uint256,address,uint256,uint256)\":{\"details\":\"triggered when report is successfully submitted\",\"params\":{\"_amount\":\"transfer amount\",\"_fromBlockchain\":\"source blockchain\",\"_reporter\":\"reporter wallet\",\"_to\":\"target wallet\",\"_txId\":\"tx id on the source blockchain\",\"_xTransferId\":\"xtransfer id\"}},\"XTransfer(address,bytes32,bytes32,uint256,uint256)\":{\"details\":\"triggered when xTransfer is successfully called\",\"params\":{\"_amount\":\"transfer amount\",\"_from\":\"wallet address that initiated the xtransfer\",\"_id\":\"xtransfer id\",\"_to\":\"target wallet\",\"_toBlockchain\":\"target blockchain\"}},\"XTransferComplete(address,uint256)\":{\"details\":\"triggered when final report is successfully submitted\",\"params\":{\"_id\":\"xtransfer id\",\"_to\":\"target wallet\"}}},\"kind\":\"dev\",\"methods\":{\"acceptOwnership()\":{\"details\":\"used by a new owner to accept an ownership transfer\"},\"constructor\":{\"details\":\"initializes a new BancorX instance\",\"params\":{\"_limitIncPerBlock\":\"how much the limit increases per block\",\"_maxLockLimit\":\"maximum amount of tokens that can be locked in one transaction\",\"_maxReleaseLimit\":\"maximum amount of tokens that can be released in one transaction\",\"_minLimit\":\"minimum amount of tokens that can be transferred in one transaction\",\"_minRequiredReports\":\"minimum number of reporters to report transaction before tokens can be released\",\"_registry\":\"address of contract registry\",\"_token\":\"erc20 token\"}},\"enableReporting(bool)\":{\"details\":\"allows the owner enable/disable the reportTransaction method\",\"params\":{\"_enable\":\"true to enable, false to disable\"}},\"enableXTransfers(bool)\":{\"details\":\"allows the owner enable/disable the xTransfer method\",\"params\":{\"_enable\":\"true to enable, false to disable\"}},\"getCurrentLockLimit()\":{\"details\":\"method for calculating current lock limit\",\"returns\":{\"_0\":\"the current maximum limit of tokens that can be locked\"}},\"getCurrentReleaseLimit()\":{\"details\":\"method for calculating current release limit\",\"returns\":{\"_0\":\"the current maximum limit of tokens that can be released\"}},\"getXTransferAmount(uint256,address)\":{\"details\":\"gets x transfer amount by xTransferId (not txId)\",\"params\":{\"_for\":\"address corresponding to xTransferId\",\"_xTransferId\":\"unique (if non zero) pre-determined id (unlike _txId which is determined after the transactions been broadcasted)\"},\"returns\":{\"_0\":\"amount that was sent in xTransfer corresponding to _xTransferId\"}},\"reportTx(bytes32,uint256,address,uint256,uint256)\":{\"details\":\"allows reporter to report transaction which occured on another blockchain\",\"params\":{\"_amount\":\"amount of tokens destroyed on another blockchain\",\"_fromBlockchain\":\"blockchain in which tokens were destroyed\",\"_to\":\"address to receive tokens\",\"_txId\":\"transactionId of transaction thats being reported\",\"_xTransferId\":\"unique (if non zero) pre-determined id (unlike _txId which is determined after the transactions been mined)\"}},\"restoreRegistry()\":{\"details\":\"restores the previous contract-registry\"},\"restrictRegistryUpdate(bool)\":{\"details\":\"restricts the permission to update the contract-registry\",\"params\":{\"_onlyOwnerCanUpdateRegistry\":\"indicates whether or not permission is restricted to owner only\"}},\"setLimitIncPerBlock(uint256)\":{\"details\":\"setter\",\"params\":{\"_limitIncPerBlock\":\"new limitIncPerBlock\"}},\"setMaxLockLimit(uint256)\":{\"details\":\"setter\",\"params\":{\"_maxLockLimit\":\"new maxLockLimit\"}},\"setMaxReleaseLimit(uint256)\":{\"details\":\"setter\",\"params\":{\"_maxReleaseLimit\":\"new maxReleaseLimit\"}},\"setMinLimit(uint256)\":{\"details\":\"setter\",\"params\":{\"_minLimit\":\"new minLimit\"}},\"setMinRequiredReports(uint8)\":{\"details\":\"setter\",\"params\":{\"_minRequiredReports\":\"new minRequiredReports\"}},\"setReporter(address,bool)\":{\"details\":\"allows the owner to set/remove reporters\",\"params\":{\"_active\":\"true if the reporter is approved, false otherwise\",\"_reporter\":\"reporter whos status is to be set\"}},\"transferOwnership(address)\":{\"details\":\"allows transferring the contract ownership the new owner still needs to accept the transfer can only be called by the contract owner\",\"params\":{\"_newOwner\":\"new contract owner\"}},\"updateRegistry()\":{\"details\":\"updates to the new contract-registry\"},\"upgrade(address[])\":{\"details\":\"upgrades the contract to the latest version can only be called by the owner note that the owner needs to call acceptOwnership on the new contract after the upgrade\",\"params\":{\"_reporters\":\"new list of reporters\"}},\"withdrawTokens(address,address,uint256)\":{\"details\":\"withdraws tokens held by the contract and sends them to an account can only be called by the owner\",\"params\":{\"_amount\":\"amount to withdraw\",\"_to\":\"account to receive the new amount\",\"_token\":\"ERC20 token contract address\"}},\"xTransfer(bytes32,bytes32,uint256)\":{\"details\":\"claims tokens from msg.sender to be converted to tokens on another blockchain\",\"params\":{\"_amount\":\"the amount of tokens to transfer\",\"_to\":\"address to send the tokens to\",\"_toBlockchain\":\"blockchain on which tokens will be issued\"}},\"xTransfer(bytes32,bytes32,uint256,uint256)\":{\"details\":\"claims tokens from msg.sender to be converted to tokens on another blockchain\",\"params\":{\"_amount\":\"the amount of tokens to transfer\",\"_id\":\"pre-determined unique (if non zero) id which refers to this transaction\",\"_to\":\"address to send the tokens to\",\"_toBlockchain\":\"blockchain on which tokens will be issued\"}}},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/bancorx/BancorX.sol\":\"BancorX\"},\"evmVersion\":\"istanbul\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":200},\"remappings\":[]},\"sources\":{\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/bancorx/BancorX.sol\":{\"keccak256\":\"0xe2b3099bba3c6688433611b13621418fb330030f4c11e43a76046ceaee03ef5c\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://971f9e6ccc18878706965dead5c2cfd92ab33a3bf73e7a256d53b4d00e8fc058\",\"dweb:/ipfs/Qmdg4tpFLzy4FVX7t9CeT9gBdmJWJzLpVsz5Dr611EtuaA\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/bancorx/interfaces/IBancorX.sol\":{\"keccak256\":\"0x65b5780d710159c7540078c38406c53db37a349fb468a0bf21bdc6262e497951\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://3df931a12770d10a22451326e38ae9d405d3e2716bdbdd6306b5e2361f6fe511\",\"dweb:/ipfs/QmcRBSaFLz516dAEqb8ZEiyx8ZTHZZ6rfxHn5roL2fHA3S\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/bancorx/interfaces/IBancorXUpgrader.sol\":{\"keccak256\":\"0x5292f6484aafd5e225b0d4f7fe61235ebee69ada5044a84e3f94014053d8a373\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://f796012a45f7d9c47239725ad638f8636146686a5a390bd85892e889a20459b2\",\"dweb:/ipfs/QmRbfxfYCssyj1PkQMdv1rsjUz35BDTLag4wrxnq4SAy2j\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/interfaces/IERC20Token.sol\":{\"keccak256\":\"0xe6f988c3156e88258474526a541d5a42b6a9adae98b04177a059d9f723bc82cd\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://9a6eb77a5b9ce70995a11a6e48ac3985a4c70896fe5fe04d46146ad7c1c83ea3\",\"dweb:/ipfs/QmYvGSveZFG51tghwkVuu6eK9Jy8frHpfLxHTMyvNZN461\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/ContractRegistryClient.sol\":{\"keccak256\":\"0x74caf88eff1cb113ad8277df9ba7933a6f1e0deea8fd1855157def3be833b859\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://c7793c9f245736cd8413bc8c4b5c40b67949cbee32289a16d29c83cf59396ad6\",\"dweb:/ipfs/QmWony7b1buUrGnE32gjLAnSwkBYMrJ68vUcCwDMmp3MbJ\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/Owned.sol\":{\"keccak256\":\"0x6ef69d9dcc80a8a36d5eb37783375cd5e4831c6d20c723fa6f6b6a06c0aeb53d\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://5a5d087e2c5b47739615ef22e1f29749de44b43c9a37cfae32b3dfc498a258c4\",\"dweb:/ipfs/Qmd1mXKEQbmBxqHk326LGVzNoayXsam8gZNecknnYpBnyh\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/SafeMath.sol\":{\"keccak256\":\"0x1ab7391a19ca8a3ad2f3c4a1074e080d4d76dfdb834637bdd0c1e6b6acdf28af\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://d6d8c99621ca884b72da2d84eddfec8ec8c5533915691d6eec94a07adf445608\",\"dweb:/ipfs/QmaXr6DN7VbfxfMn3PsTy7SAMgZVVXbdeaw11BsAjVL2x1\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/TokenHandler.sol\":{\"keccak256\":\"0xf65b87e3bf3343e368da67878c19d1a043a1025b10e9053d3562b53b4aa447fe\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://b85c5d96642c14c53b8d5062eecd4d27d3bdb457d1d0f130900763a75a512eb7\",\"dweb:/ipfs/QmUHtbqC1khqnRZXYn11Aykus4m5e9MVNUWqorxhpr5ipJ\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/TokenHolder.sol\":{\"keccak256\":\"0xac6bc102eff6c1bb8c1bb4466eab50322c7c101e2e33d577dd3035f106627577\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://9fdbda2d4509260ca3dd43654bdaea07ef18a5e04213ff16e38e3b4abad78a5f\",\"dweb:/ipfs/QmPb69rzX1DwDeEhhfzqQNS3U2bfGcFjXNaV5ffHsZHzfP\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/Utils.sol\":{\"keccak256\":\"0x073efa69fcd6b5e60f841b28b366d63b62ff48ab12a06ce3f5a7f41afd6ce885\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://e8b8ecb2d29197ca77f0ed98f728ace54e6edcfdf5cd1194ae22701607eaf608\",\"dweb:/ipfs/QmcsR6Q35Hurh3TrPkYAboicz9bQQoGCWmZLzUCDyhotH8\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/interfaces/IContractRegistry.sol\":{\"keccak256\":\"0x3551889a83738b621c29ed66f1ecb6a843cca4217e54c9357198559b9cc92259\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://231a59c8f2665adeda8c7e6930832409c9b991fd27ad84b3a24335e7bf269bbe\",\"dweb:/ipfs/QmeJJbn1EAUbZenruTEdJAnwUn3dxsVNeJvxPe81qKEGqL\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/interfaces/IOwned.sol\":{\"keccak256\":\"0xc60a9d197abc28c1906ed4d18b59caa0242db754a0e1f67af6e6277593530dae\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://a8c6f3e6525a81a5165ccbf04f73f6c389c14b74135d11a7b5f70b1c9bdac75c\",\"dweb:/ipfs/QmaPu4Z7yUPc9sMADmoTZVY6AnyDSYHtNNCx3mm4VkJwhP\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/interfaces/ITokenHolder.sol\":{\"keccak256\":\"0x9ccb8ab04d0bd874ba7aae5277e60f35c36918922649a0596bf3664ed257bfe2\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://b65e6db19cd244c9f3545695de5fd7573711c49fb306631ddbf0e1d2fa9fb589\",\"dweb:/ipfs/QmZeu5KYVMTbTx7h2BVUq52fpwL9Q44AUfzeVksucDohgf\"]}},\"version\":1}",
+ "bytecode": "0x6080604052600c805460ff60b01b1960ff60a81b19909116600160a81b1716600160b01b1790553480156200003357600080fd5b506040516200205938038062002059833981810160405260e08110156200005957600080fd5b508051602082015160408301516060840151608085015160a086015160c090960151600080546001600160a01b0319163317905594959394929391929091908180620000a581620001f6565b50600280546001600160a01b039092166001600160a01b031992831681179091556003805490921617905586620000dc8162000255565b86620000e88162000255565b86620000f48162000255565b86620001008162000255565b60ff87166200010f8162000255565b856200011b81620001f6565b8662000127816200029c565b8d8c111580156200013857508c8c11155b6200018a576040805162461bcd60e51b815260206004820152601560248201527f4552525f494e56414c49445f4d494e5f4c494d49540000000000000000000000604482015290519081900360640190fd5b50505060048b905550505060058790555060069490945550600991909155600c805460079590955560089390935543600a819055600b556001600160a01b0390911661010002610100600160a81b031960ff90921660ff199094169390931716919091179055620002fb565b6001600160a01b03811662000252576040805162461bcd60e51b815260206004820152601360248201527f4552525f494e56414c49445f4144445245535300000000000000000000000000604482015290519081900360640190fd5b50565b6000811162000252576040805162461bcd60e51b815260206004820152600e60248201526d4552525f5a45524f5f56414c554560901b604482015290519081900360640190fd5b6001600160a01b03811630141562000252576040805162461bcd60e51b815260206004820152601360248201527f4552525f414444524553535f49535f53454c4600000000000000000000000000604482015290519081900360640190fd5b611d4e806200030b6000396000f3fe608060405234801561001057600080fd5b50600436106102695760003560e01c80637b10399911610151578063b4a176d3116100c3578063e36f8dc511610087578063e36f8dc5146106c1578063ed1d73a6146106de578063f2fde38b146106fd578063f7385f7614610723578063fbb246921461072b578063fc0c546a1461073357610269565b8063b4a176d314610648578063bf28ece414610650578063ca27e0111461066d578063d4ee1d901461068b578063e1bb51331461069357610269565b80639ace38c2116101155780639ace38c214610566578063a50c326c146105bb578063a5c670ca146105d8578063a8c36a90146105f7578063aafd6b76146105ff578063af2b96181461062b57610269565b80637b103999146105025780637b15879c1461050a5780638544c52d1461052a5780638da5cb5b146105565780639390701c1461055e57610269565b806349282538116101ea5780635e35359e116101ae5780635e35359e1461043d57806361cd756e146104735780636dc6a01b146104975780636ec6d4a6146104d557806372f43d19146104f257806379ba5097146104fa57610269565b806349282538146103dd57806349d10b64146104065780634b3e475c1461040e57806352e94ce31461041657806354fd4d501461041e57610269565b80631e04a593116102315780631e04a5931461035c5780631fd8088d146103645780632cc1cd9e1461036c5780632fe8a6ad146103a6578063427c0374146103ae57610269565b80630183592b1461026e578063024c7ec71461031357806316c76c2714610332578063199674391461034c5780631aff29eb14610354575b600080fd5b6103116004803603602081101561028457600080fd5b81019060208101813564010000000081111561029f57600080fd5b8201836020820111156102b157600080fd5b803590602001918460208302840111640100000000831117156102d357600080fd5b91908080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525092955061073b945050505050565b005b6103116004803603602081101561032957600080fd5b5035151561081a565b61033a610840565b60408051918252519081900360200190f35b61033a610846565b61033a610892565b61033a610898565b61033a6108d8565b6103926004803603602081101561038257600080fd5b50356001600160a01b03166108de565b604080519115158252519081900360200190f35b6103926108f3565b610311600480360360808110156103c457600080fd5b5080359060208101359060408101359060600135610903565b610311600480360360608110156103f357600080fd5b50803590602081013590604001356109d5565b610311610aa6565b61033a610cae565b61033a610cb4565b610426610cba565b6040805161ffff9092168252519081900360200190f35b6103116004803603606081101561045357600080fd5b506001600160a01b03813581169160208101359091169060400135610cbf565b61047b610cf8565b604080516001600160a01b039092168252519081900360200190f35b610311600480360360a08110156104ad57600080fd5b508035906020810135906001600160a01b036040820135169060608101359060800135610d07565b610311600480360360208110156104eb57600080fd5b50356110c5565b61033a61113a565b610311611140565b61047b6111f7565b6103116004803603602081101561052057600080fd5b503560ff16611206565b6103926004803603604081101561054057600080fd5b50803590602001356001600160a01b0316611232565b61047b611252565b610392611261565b6105836004803603602081101561057c57600080fd5b5035611271565b6040805195865260208601949094526001600160a01b039092168484015260ff16606084015215156080830152519081900360a00190f35b610311600480360360208110156105d157600080fd5b50356112b1565b610311600480360360208110156105ee57600080fd5b503515156112c9565b61033a6112ef565b61033a6004803603604081101561061557600080fd5b50803590602001356001600160a01b03166112f5565b6103116004803603602081101561064157600080fd5b50356113be565b6103116113d6565b6103116004803603602081101561066657600080fd5b5035611402565b61067561141a565b6040805160ff9092168252519081900360200190f35b61047b611423565b610311600480360360408110156106a957600080fd5b506001600160a01b0381351690602001351515611432565b61033a600480360360208110156106d757600080fd5b5035611465565b610311600480360360208110156106f457600080fd5b50351515611477565b6103116004803603602081101561071357600080fd5b50356001600160a01b031661149d565b61033a61151b565b610392611521565b61047b611531565b610743611545565b60006107606e2130b731b7b92c2ab833b930b232b960891b61159a565b905061076b8161149d565b6040805163151a1cb360e21b81526004818101818152602483019384528551604484015285516001600160a01b0386169463546872cc948893926064909101906020808601910280838360005b838110156107d05781810151838201526020016107b8565b505050509050019350505050600060405180830381600087803b1580156107f657600080fd5b505af115801561080a573d6000803e3d6000fd5b50505050610816611140565b5050565b610822611545565b60038054911515600160a01b0260ff60a01b19909216919091179055565b60075481565b60008061087661086d600954610867600a544361161890919063ffffffff16565b90611665565b600754906116ca565b905060045481111561088c57505060045461088f565b90505b90565b600a5481565b6000806108c26108b9600954610867600b544361161890919063ffffffff16565b600854906116ca565b905060055481111561088c57505060055461088f565b60065481565b60106020526000908152604090205460ff1681565b600354600160a01b900460ff1681565b61090b611713565b6000610915610846565b905060065483101580156109295750808311155b610970576040805162461bcd60e51b815260206004820152601360248201527208aa4a4be829a9eaa9ca8bea89e9ebe90928e9606b1b604482015290519081900360640190fd5b61097983611760565b6109838184611618565b60075543600a5560408051868152602081018590528082018490529051859133917f4780f3edc9124597ede658e04ed3d8887b58c86943b2a805dc961cf512570b629181900360600190a35050505050565b6109dd611713565b60006109e7610846565b905060065482101580156109fb5750808211155b610a42576040805162461bcd60e51b815260206004820152601360248201527208aa4a4be829a9eaa9ca8bea89e9ebe90928e9606b1b604482015290519081900360640190fd5b610a4b82611760565b610a558183611618565b60075543600a5560408051858152602081018490526000818301529051849133917f4780f3edc9124597ede658e04ed3d8887b58c86943b2a805dc961cf512570b629181900360600190a350505050565b6000546001600160a01b0316331480610ac95750600354600160a01b900460ff16155b610b0e576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b6000610b2c6f436f6e7472616374526567697374727960801b61159a565b6002549091506001600160a01b03808316911614801590610b5557506001600160a01b03811615155b610b9d576040805162461bcd60e51b81526020600482015260146024820152734552525f494e56414c49445f524547495354525960601b604482015290519081900360640190fd5b60006001600160a01b0316816001600160a01b031663bb34534c6f436f6e7472616374526567697374727960801b6040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b158015610bff57600080fd5b505afa158015610c13573d6000803e3d6000fd5b505050506040513d6020811015610c2957600080fd5b50516001600160a01b03161415610c7e576040805162461bcd60e51b81526020600482015260146024820152734552525f494e56414c49445f524547495354525960601b604482015290519081900360640190fd5b60028054600380546001600160a01b038084166001600160a01b0319928316179092559091169216919091179055565b600b5481565b60055481565b600481565b610cc7611545565b82610cd1816117b6565b82610cdb816117b6565b83610ce58161180a565b610cf086868661185e565b505050505050565b6003546001600160a01b031681565b610d0f6119be565b610d17611a16565b82610d21816117b6565b82610d2b81611a63565b6000868152600f6020908152604080832033845290915290205460ff1615610d91576040805162461bcd60e51b815260206004820152601460248201527311549497d053149150511657d4915413d495115160621b604482015290519081900360640190fd5b6000868152600f602090815260408083203384528252808320805460ff19166001179055888352600d90915290206002810154600160a01b900460ff16610e6f576002810180546001600160a01b0319166001600160a01b038816179055848155600181018890558315610e6a576000848152600e602052604090205415610e58576040805162461bcd60e51b81526020600482015260156024820152744552525f54585f414c52454144595f45584953545360581b604482015290519081900360640190fd5b6000848152600e602052604090208790555b610f40565b60028101546001600160a01b038781169116148015610e8e5750805485145b8015610e9d5750878160010154145b610ee0576040805162461bcd60e51b815260206004820152600f60248201526e08aa4a4bea8b0be9a92a69a82a8869608b1b604482015290519081900360640190fd5b8315610f40576000848152600e60205260409020548714610f40576040805162461bcd60e51b81526020600482015260156024820152744552525f54585f414c52454144595f45584953545360581b604482015290519081900360640190fd5b600281018054600160ff600160a01b808404821692909201160260ff60a01b1990911617905560408051898152602081018990526001600160a01b038816818301526060810187905260808101869052905133917f5e77831e701760f7f4a1e61a8e9834d773b52c45d91ba9006b7d2afb7a144739919081900360a00190a2600c54600282015460ff918216600160a01b909104909116106110bb576000878152600d6020526040902060020154600160a81b900460ff161561104a576040805162461bcd60e51b815260206004820152601860248201527f4552525f54585f414c52454144595f434f4d504c455445440000000000000000604482015290519081900360640190fd5b6000878152600d6020908152604091829020600201805460ff60a81b1916600160a81b17905581516001600160a01b038916815290810186905281517fd87906b7fce534fc5e6dde30064e777d92d0aaf3a28c72315de8ef2e4134dfef929181900390910190a16110bb8686611aa9565b5050505050505050565b6110cd611545565b806110d781611a63565b60045482111580156110eb57506005548211155b611134576040805162461bcd60e51b815260206004820152601560248201527411549497d253959053125117d3525397d312535255605a1b604482015290519081900360640190fd5b50600655565b60095481565b6001546001600160a01b03163314611193576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b600154600080546040516001600160a01b0393841693909116917f343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a91a360018054600080546001600160a01b03199081166001600160a01b03841617909155169055565b6002546001600160a01b031681565b61120e611545565b8060ff1661121b81611a63565b50600c805460ff191660ff92909216919091179055565b600f60209081526000928352604080842090915290825290205460ff1681565b6000546001600160a01b031681565b600c54600160b01b900460ff1681565b600d602052600090815260409020805460018201546002909201549091906001600160a01b0381169060ff600160a01b8204811691600160a81b90041685565b6112b9611545565b806112c381611a63565b50600955565b6112d1611545565b600c8054911515600160a81b0260ff60a81b19909216919091179055565b60045481565b60006112ff611cea565b506000838152600e60209081526040808320548352600d825291829020825160a08101845281548152600182015492810192909252600201546001600160a01b0380821693830184905260ff600160a01b830481166060850152600160a81b909204909116151560808301529091908416146113b4576040805162461bcd60e51b815260206004820152600f60248201526e08aa4a4bea8b0be9a92a69a82a8869608b1b604482015290519081900360640190fd5b5190505b92915050565b6113c6611545565b806113d081611a63565b50600455565b6113de611545565b600354600280546001600160a01b0319166001600160a01b03909216919091179055565b61140a611545565b8061141481611a63565b50600555565b600c5460ff1681565b6001546001600160a01b031681565b61143a611545565b6001600160a01b03919091166000908152601060205260409020805460ff1916911515919091179055565b600e6020526000908152604090205481565b61147f611545565b600c8054911515600160b01b0260ff60b01b19909216919091179055565b6114a5611545565b6000546001600160a01b03828116911614156114f9576040805162461bcd60e51b815260206004820152600e60248201526d22a9292fa9a0a6a2afa7aba722a960911b604482015290519081900360640190fd5b600180546001600160a01b0319166001600160a01b0392909216919091179055565b60085481565b600c54600160a81b900460ff1681565b600c5461010090046001600160a01b031681565b6000546001600160a01b03163314611598576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b565b60025460408051632ecd14d360e21b81526004810184905290516000926001600160a01b03169163bb34534c916024808301926020929190829003018186803b1580156115e657600080fd5b505afa1580156115fa573d6000803e3d6000fd5b505050506040513d602081101561161057600080fd5b505192915050565b60008183101561165f576040805162461bcd60e51b815260206004820152600d60248201526c4552525f554e444552464c4f5760981b604482015290519081900360640190fd5b50900390565b600082611674575060006113b8565b8282028284828161168157fe5b04146116c3576040805162461bcd60e51b815260206004820152600c60248201526b4552525f4f564552464c4f5760a01b604482015290519081900360640190fd5b9392505050565b6000828201838110156116c3576040805162461bcd60e51b815260206004820152600c60248201526b4552525f4f564552464c4f5760a01b604482015290519081900360640190fd5b600c54600160a81b900460ff16611598576040805162461bcd60e51b815260206004820152600c60248201526b11549497d11254d05093115160a21b604482015290519081900360640190fd5b600c5461177d9061010090046001600160a01b0316333084611b7f565b60408051828152905133917ff5d7535a395393675f56d066384113754ca9cf4abd37298469934e2e9c2ec902919081900360200190a250565b6001600160a01b038116611807576040805162461bcd60e51b81526020600482015260136024820152724552525f494e56414c49445f4144445245535360681b604482015290519081900360640190fd5b50565b6001600160a01b038116301415611807576040805162461bcd60e51b815260206004820152601360248201527222a9292fa0a2222922a9a9afa4a9afa9a2a62360691b604482015290519081900360640190fd5b604080516001600160a01b038481166024830152604480830185905283518084039091018152606490920183526020820180516001600160e01b031663a9059cbb60e01b178152925182516000946060949389169392918291908083835b602083106118db5780518252601f1990920191602091820191016118bc565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d806000811461193d576040519150601f19603f3d011682016040523d82523d6000602084013e611942565b606091505b5091509150818015611970575080511580611970575080806020019051602081101561196d57600080fd5b50515b6119b7576040805162461bcd60e51b815260206004820152601360248201527211549497d514905394d1915497d19052531151606a1b604482015290519081900360640190fd5b5050505050565b3360009081526010602052604090205460ff16611598576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b600c54600160b01b900460ff16611598576040805162461bcd60e51b815260206004820152600c60248201526b11549497d11254d05093115160a21b604482015290519081900360640190fd5b60008111611807576040805162461bcd60e51b815260206004820152600e60248201526d4552525f5a45524f5f56414c554560901b604482015290519081900360640190fd5b6000611ab3610898565b90506006548210158015611ac75750808211155b611b0e576040805162461bcd60e51b815260206004820152601360248201527208aa4a4be829a9eaa9ca8bea89e9ebe90928e9606b1b604482015290519081900360640190fd5b611b188183611618565b60085543600b55600c54611b3b9061010090046001600160a01b0316848461185e565b6040805183815290516001600160a01b038516917fbfdc1f3c02b4715077e0be4a262f967d53d4d0fcd76c6987fa2ad6e2257d7c8f919081900360200190a2505050565b604080516001600160a01b0385811660248301528481166044830152606480830185905283518084039091018152608490920183526020820180516001600160e01b03166323b872dd60e01b17815292518251600094606094938a169392918291908083835b60208310611c045780518252601f199092019160209182019101611be5565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d8060008114611c66576040519150601f19603f3d011682016040523d82523d6000602084013e611c6b565b606091505b5091509150818015611c99575080511580611c995750808060200190516020811015611c9657600080fd5b50515b610cf0576040805162461bcd60e51b815260206004820152601860248201527f4552525f5452414e534645525f46524f4d5f4641494c45440000000000000000604482015290519081900360640190fd5b6040805160a0810182526000808252602082018190529181018290526060810182905260808101919091529056fea2646970667358221220115bb7a48a11cc43f6e7bee4df69098380dfe3262177df02543cafb26cc9deda64736f6c634300060c0033",
+ "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106102695760003560e01c80637b10399911610151578063b4a176d3116100c3578063e36f8dc511610087578063e36f8dc5146106c1578063ed1d73a6146106de578063f2fde38b146106fd578063f7385f7614610723578063fbb246921461072b578063fc0c546a1461073357610269565b8063b4a176d314610648578063bf28ece414610650578063ca27e0111461066d578063d4ee1d901461068b578063e1bb51331461069357610269565b80639ace38c2116101155780639ace38c214610566578063a50c326c146105bb578063a5c670ca146105d8578063a8c36a90146105f7578063aafd6b76146105ff578063af2b96181461062b57610269565b80637b103999146105025780637b15879c1461050a5780638544c52d1461052a5780638da5cb5b146105565780639390701c1461055e57610269565b806349282538116101ea5780635e35359e116101ae5780635e35359e1461043d57806361cd756e146104735780636dc6a01b146104975780636ec6d4a6146104d557806372f43d19146104f257806379ba5097146104fa57610269565b806349282538146103dd57806349d10b64146104065780634b3e475c1461040e57806352e94ce31461041657806354fd4d501461041e57610269565b80631e04a593116102315780631e04a5931461035c5780631fd8088d146103645780632cc1cd9e1461036c5780632fe8a6ad146103a6578063427c0374146103ae57610269565b80630183592b1461026e578063024c7ec71461031357806316c76c2714610332578063199674391461034c5780631aff29eb14610354575b600080fd5b6103116004803603602081101561028457600080fd5b81019060208101813564010000000081111561029f57600080fd5b8201836020820111156102b157600080fd5b803590602001918460208302840111640100000000831117156102d357600080fd5b91908080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525092955061073b945050505050565b005b6103116004803603602081101561032957600080fd5b5035151561081a565b61033a610840565b60408051918252519081900360200190f35b61033a610846565b61033a610892565b61033a610898565b61033a6108d8565b6103926004803603602081101561038257600080fd5b50356001600160a01b03166108de565b604080519115158252519081900360200190f35b6103926108f3565b610311600480360360808110156103c457600080fd5b5080359060208101359060408101359060600135610903565b610311600480360360608110156103f357600080fd5b50803590602081013590604001356109d5565b610311610aa6565b61033a610cae565b61033a610cb4565b610426610cba565b6040805161ffff9092168252519081900360200190f35b6103116004803603606081101561045357600080fd5b506001600160a01b03813581169160208101359091169060400135610cbf565b61047b610cf8565b604080516001600160a01b039092168252519081900360200190f35b610311600480360360a08110156104ad57600080fd5b508035906020810135906001600160a01b036040820135169060608101359060800135610d07565b610311600480360360208110156104eb57600080fd5b50356110c5565b61033a61113a565b610311611140565b61047b6111f7565b6103116004803603602081101561052057600080fd5b503560ff16611206565b6103926004803603604081101561054057600080fd5b50803590602001356001600160a01b0316611232565b61047b611252565b610392611261565b6105836004803603602081101561057c57600080fd5b5035611271565b6040805195865260208601949094526001600160a01b039092168484015260ff16606084015215156080830152519081900360a00190f35b610311600480360360208110156105d157600080fd5b50356112b1565b610311600480360360208110156105ee57600080fd5b503515156112c9565b61033a6112ef565b61033a6004803603604081101561061557600080fd5b50803590602001356001600160a01b03166112f5565b6103116004803603602081101561064157600080fd5b50356113be565b6103116113d6565b6103116004803603602081101561066657600080fd5b5035611402565b61067561141a565b6040805160ff9092168252519081900360200190f35b61047b611423565b610311600480360360408110156106a957600080fd5b506001600160a01b0381351690602001351515611432565b61033a600480360360208110156106d757600080fd5b5035611465565b610311600480360360208110156106f457600080fd5b50351515611477565b6103116004803603602081101561071357600080fd5b50356001600160a01b031661149d565b61033a61151b565b610392611521565b61047b611531565b610743611545565b60006107606e2130b731b7b92c2ab833b930b232b960891b61159a565b905061076b8161149d565b6040805163151a1cb360e21b81526004818101818152602483019384528551604484015285516001600160a01b0386169463546872cc948893926064909101906020808601910280838360005b838110156107d05781810151838201526020016107b8565b505050509050019350505050600060405180830381600087803b1580156107f657600080fd5b505af115801561080a573d6000803e3d6000fd5b50505050610816611140565b5050565b610822611545565b60038054911515600160a01b0260ff60a01b19909216919091179055565b60075481565b60008061087661086d600954610867600a544361161890919063ffffffff16565b90611665565b600754906116ca565b905060045481111561088c57505060045461088f565b90505b90565b600a5481565b6000806108c26108b9600954610867600b544361161890919063ffffffff16565b600854906116ca565b905060055481111561088c57505060055461088f565b60065481565b60106020526000908152604090205460ff1681565b600354600160a01b900460ff1681565b61090b611713565b6000610915610846565b905060065483101580156109295750808311155b610970576040805162461bcd60e51b815260206004820152601360248201527208aa4a4be829a9eaa9ca8bea89e9ebe90928e9606b1b604482015290519081900360640190fd5b61097983611760565b6109838184611618565b60075543600a5560408051868152602081018590528082018490529051859133917f4780f3edc9124597ede658e04ed3d8887b58c86943b2a805dc961cf512570b629181900360600190a35050505050565b6109dd611713565b60006109e7610846565b905060065482101580156109fb5750808211155b610a42576040805162461bcd60e51b815260206004820152601360248201527208aa4a4be829a9eaa9ca8bea89e9ebe90928e9606b1b604482015290519081900360640190fd5b610a4b82611760565b610a558183611618565b60075543600a5560408051858152602081018490526000818301529051849133917f4780f3edc9124597ede658e04ed3d8887b58c86943b2a805dc961cf512570b629181900360600190a350505050565b6000546001600160a01b0316331480610ac95750600354600160a01b900460ff16155b610b0e576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b6000610b2c6f436f6e7472616374526567697374727960801b61159a565b6002549091506001600160a01b03808316911614801590610b5557506001600160a01b03811615155b610b9d576040805162461bcd60e51b81526020600482015260146024820152734552525f494e56414c49445f524547495354525960601b604482015290519081900360640190fd5b60006001600160a01b0316816001600160a01b031663bb34534c6f436f6e7472616374526567697374727960801b6040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b158015610bff57600080fd5b505afa158015610c13573d6000803e3d6000fd5b505050506040513d6020811015610c2957600080fd5b50516001600160a01b03161415610c7e576040805162461bcd60e51b81526020600482015260146024820152734552525f494e56414c49445f524547495354525960601b604482015290519081900360640190fd5b60028054600380546001600160a01b038084166001600160a01b0319928316179092559091169216919091179055565b600b5481565b60055481565b600481565b610cc7611545565b82610cd1816117b6565b82610cdb816117b6565b83610ce58161180a565b610cf086868661185e565b505050505050565b6003546001600160a01b031681565b610d0f6119be565b610d17611a16565b82610d21816117b6565b82610d2b81611a63565b6000868152600f6020908152604080832033845290915290205460ff1615610d91576040805162461bcd60e51b815260206004820152601460248201527311549497d053149150511657d4915413d495115160621b604482015290519081900360640190fd5b6000868152600f602090815260408083203384528252808320805460ff19166001179055888352600d90915290206002810154600160a01b900460ff16610e6f576002810180546001600160a01b0319166001600160a01b038816179055848155600181018890558315610e6a576000848152600e602052604090205415610e58576040805162461bcd60e51b81526020600482015260156024820152744552525f54585f414c52454144595f45584953545360581b604482015290519081900360640190fd5b6000848152600e602052604090208790555b610f40565b60028101546001600160a01b038781169116148015610e8e5750805485145b8015610e9d5750878160010154145b610ee0576040805162461bcd60e51b815260206004820152600f60248201526e08aa4a4bea8b0be9a92a69a82a8869608b1b604482015290519081900360640190fd5b8315610f40576000848152600e60205260409020548714610f40576040805162461bcd60e51b81526020600482015260156024820152744552525f54585f414c52454144595f45584953545360581b604482015290519081900360640190fd5b600281018054600160ff600160a01b808404821692909201160260ff60a01b1990911617905560408051898152602081018990526001600160a01b038816818301526060810187905260808101869052905133917f5e77831e701760f7f4a1e61a8e9834d773b52c45d91ba9006b7d2afb7a144739919081900360a00190a2600c54600282015460ff918216600160a01b909104909116106110bb576000878152600d6020526040902060020154600160a81b900460ff161561104a576040805162461bcd60e51b815260206004820152601860248201527f4552525f54585f414c52454144595f434f4d504c455445440000000000000000604482015290519081900360640190fd5b6000878152600d6020908152604091829020600201805460ff60a81b1916600160a81b17905581516001600160a01b038916815290810186905281517fd87906b7fce534fc5e6dde30064e777d92d0aaf3a28c72315de8ef2e4134dfef929181900390910190a16110bb8686611aa9565b5050505050505050565b6110cd611545565b806110d781611a63565b60045482111580156110eb57506005548211155b611134576040805162461bcd60e51b815260206004820152601560248201527411549497d253959053125117d3525397d312535255605a1b604482015290519081900360640190fd5b50600655565b60095481565b6001546001600160a01b03163314611193576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b600154600080546040516001600160a01b0393841693909116917f343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a91a360018054600080546001600160a01b03199081166001600160a01b03841617909155169055565b6002546001600160a01b031681565b61120e611545565b8060ff1661121b81611a63565b50600c805460ff191660ff92909216919091179055565b600f60209081526000928352604080842090915290825290205460ff1681565b6000546001600160a01b031681565b600c54600160b01b900460ff1681565b600d602052600090815260409020805460018201546002909201549091906001600160a01b0381169060ff600160a01b8204811691600160a81b90041685565b6112b9611545565b806112c381611a63565b50600955565b6112d1611545565b600c8054911515600160a81b0260ff60a81b19909216919091179055565b60045481565b60006112ff611cea565b506000838152600e60209081526040808320548352600d825291829020825160a08101845281548152600182015492810192909252600201546001600160a01b0380821693830184905260ff600160a01b830481166060850152600160a81b909204909116151560808301529091908416146113b4576040805162461bcd60e51b815260206004820152600f60248201526e08aa4a4bea8b0be9a92a69a82a8869608b1b604482015290519081900360640190fd5b5190505b92915050565b6113c6611545565b806113d081611a63565b50600455565b6113de611545565b600354600280546001600160a01b0319166001600160a01b03909216919091179055565b61140a611545565b8061141481611a63565b50600555565b600c5460ff1681565b6001546001600160a01b031681565b61143a611545565b6001600160a01b03919091166000908152601060205260409020805460ff1916911515919091179055565b600e6020526000908152604090205481565b61147f611545565b600c8054911515600160b01b0260ff60b01b19909216919091179055565b6114a5611545565b6000546001600160a01b03828116911614156114f9576040805162461bcd60e51b815260206004820152600e60248201526d22a9292fa9a0a6a2afa7aba722a960911b604482015290519081900360640190fd5b600180546001600160a01b0319166001600160a01b0392909216919091179055565b60085481565b600c54600160a81b900460ff1681565b600c5461010090046001600160a01b031681565b6000546001600160a01b03163314611598576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b565b60025460408051632ecd14d360e21b81526004810184905290516000926001600160a01b03169163bb34534c916024808301926020929190829003018186803b1580156115e657600080fd5b505afa1580156115fa573d6000803e3d6000fd5b505050506040513d602081101561161057600080fd5b505192915050565b60008183101561165f576040805162461bcd60e51b815260206004820152600d60248201526c4552525f554e444552464c4f5760981b604482015290519081900360640190fd5b50900390565b600082611674575060006113b8565b8282028284828161168157fe5b04146116c3576040805162461bcd60e51b815260206004820152600c60248201526b4552525f4f564552464c4f5760a01b604482015290519081900360640190fd5b9392505050565b6000828201838110156116c3576040805162461bcd60e51b815260206004820152600c60248201526b4552525f4f564552464c4f5760a01b604482015290519081900360640190fd5b600c54600160a81b900460ff16611598576040805162461bcd60e51b815260206004820152600c60248201526b11549497d11254d05093115160a21b604482015290519081900360640190fd5b600c5461177d9061010090046001600160a01b0316333084611b7f565b60408051828152905133917ff5d7535a395393675f56d066384113754ca9cf4abd37298469934e2e9c2ec902919081900360200190a250565b6001600160a01b038116611807576040805162461bcd60e51b81526020600482015260136024820152724552525f494e56414c49445f4144445245535360681b604482015290519081900360640190fd5b50565b6001600160a01b038116301415611807576040805162461bcd60e51b815260206004820152601360248201527222a9292fa0a2222922a9a9afa4a9afa9a2a62360691b604482015290519081900360640190fd5b604080516001600160a01b038481166024830152604480830185905283518084039091018152606490920183526020820180516001600160e01b031663a9059cbb60e01b178152925182516000946060949389169392918291908083835b602083106118db5780518252601f1990920191602091820191016118bc565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d806000811461193d576040519150601f19603f3d011682016040523d82523d6000602084013e611942565b606091505b5091509150818015611970575080511580611970575080806020019051602081101561196d57600080fd5b50515b6119b7576040805162461bcd60e51b815260206004820152601360248201527211549497d514905394d1915497d19052531151606a1b604482015290519081900360640190fd5b5050505050565b3360009081526010602052604090205460ff16611598576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b600c54600160b01b900460ff16611598576040805162461bcd60e51b815260206004820152600c60248201526b11549497d11254d05093115160a21b604482015290519081900360640190fd5b60008111611807576040805162461bcd60e51b815260206004820152600e60248201526d4552525f5a45524f5f56414c554560901b604482015290519081900360640190fd5b6000611ab3610898565b90506006548210158015611ac75750808211155b611b0e576040805162461bcd60e51b815260206004820152601360248201527208aa4a4be829a9eaa9ca8bea89e9ebe90928e9606b1b604482015290519081900360640190fd5b611b188183611618565b60085543600b55600c54611b3b9061010090046001600160a01b0316848461185e565b6040805183815290516001600160a01b038516917fbfdc1f3c02b4715077e0be4a262f967d53d4d0fcd76c6987fa2ad6e2257d7c8f919081900360200190a2505050565b604080516001600160a01b0385811660248301528481166044830152606480830185905283518084039091018152608490920183526020820180516001600160e01b03166323b872dd60e01b17815292518251600094606094938a169392918291908083835b60208310611c045780518252601f199092019160209182019101611be5565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d8060008114611c66576040519150601f19603f3d011682016040523d82523d6000602084013e611c6b565b606091505b5091509150818015611c99575080511580611c995750808060200190516020811015611c9657600080fd5b50515b610cf0576040805162461bcd60e51b815260206004820152601860248201527f4552525f5452414e534645525f46524f4d5f4641494c45440000000000000000604482015290519081900360640190fd5b6040805160a0810182526000808252602082018190529181018290526060810182905260808101919091529056fea2646970667358221220115bb7a48a11cc43f6e7bee4df69098380dfe3262177df02543cafb26cc9deda64736f6c634300060c0033",
+ "immutableReferences": {},
+ "sourceMap": "900:17593:3:-:0;;;2305:36;;;-1:-1:-1;;;;;;;;2305:36:3;;;-1:-1:-1;;;2305:36:3;2399:35;-1:-1:-1;;;2399:35:3;;;5579:1321;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;5579:1321:3;;;;;;;;;;;;;;;;;;;;;;;;;;;619:5:57;:18;;-1:-1:-1;;;;;;619:18:57;627:10;619:18;;;5579:1321:3;;;;;;;;;;;;;594:23:64;5579:1321:3;594:13:64;:23::i;:::-;-1:-1:-1;2122:8:56::1;:39:::0;;-1:-1:-1;;;;;2122:39:56;;::::1;-1:-1:-1::0;;;;;;2122:39:56;;::::1;::::0;::::1;::::0;;;2172:12:::1;:43:::0;;;;::::1;;::::0;;5909:13:3;252:24:64::1;5909:13:3::0;252:16:64::1;:24::i;:::-;5949:16:3::0;252:24:64::2;5949:16:3::0;252::64::2;:24::i;:::-;5992:9:3::0;252:24:64::3;5992:9:3::0;252:16:64::3;:24::i;:::-;6028:17:3::0;252:24:64::4;6028:17:3::0;252:16:64::4;:24::i;:::-;200:96:::5;::::0;::::5;252:24;200:96:::0;252:16:::5;:24::i;:::-;6123:6:3::0;594:23:64::6;6123:6:3::0;594:13:64::6;:23::i;:::-;6157:6:3::0;948:18:64::7;6157:6:3::0;948:8:64::7;:18::i;:::-;6230:13:3::8;6217:9;:26;;:59;;;;;6260:16;6247:9;:29;;6217:59;6209:93;;;::::0;;-1:-1:-1;;;6209:93:3;;::::8;;::::0;::::8;::::0;::::8;::::0;;;;::::8;::::0;;;;;;;;;;;;;::::8;;-1:-1:-1::0;;;6391:12:3::8;:28:::0;;;-1:-1:-1;;;6430:15:3::8;:34:::0;;;-1:-1:-1;6475:8:3::8;:20:::0;;;;-1:-1:-1;6506:16:3::8;:36:::0;;;;6553:18:::8;:40:::0;;6697:13:::8;:29:::0;;;;6737:16:::8;:35:::0;;;;6805:12:::8;6783:19;:34:::0;;;6828:22:::8;:37:::0;-1:-1:-1;;;;;6878:14:3;;::::8;6553:40;6878:14;-1:-1:-1::0;;;;;;6553:40:3::8;::::0;;::::8;-1:-1:-1::0;;6553:40:3;;::::8;::::0;;;::::8;6878:14;::::0;;;::::8;::::0;;900:17593;;692:128:64;-1:-1:-1;;;;;766:22:64;;758:54;;;;;-1:-1:-1;;;758:54:64;;;;;;;;;;;;;;;;;;;;;;;;;;;;692:128;:::o;351:112::-;435:1;426:6;:10;418:37;;;;;-1:-1:-1;;;418:37:64;;;;;;;;;;;;-1:-1:-1;;;418:37:64;;;;;;;;;;;;;;1041:126;-1:-1:-1;;;;;1110:25:64;;1130:4;1110:25;;1102:57;;;;;-1:-1:-1;;;1102:57:64;;;;;;;;;;;;;;;;;;;;;;;;;;;900:17593:3;;;;;;;",
+ "deployedSourceMap": "900:17593:3:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;10400:302;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;10400:302:3;;-1:-1:-1;10400:302:3;;-1:-1:-1;;;;;10400:302:3:i;:::-;;3655:224:56;;;;;;;;;;;;;;;;-1:-1:-1;3655:224:56;;;;:::i;1675:28:3:-;;;:::i;:::-;;;;;;;;;;;;;;;;16338:392;;;:::i;1949:34::-;;;:::i;16898:422::-;;;:::i;1555:23::-;;;:::i;2856:42::-;;;;;;;;;;;;;;;;-1:-1:-1;2856:42:3;-1:-1:-1;;;;;2856:42:3;;:::i;:::-;;;;;;;;;;;;;;;;;;1333:38:56;;;:::i;12106:684:3:-;;;;;;;;;;;;;;;;-1:-1:-1;12106:684:3;;;;;;;;;;;;;;;;;:::i;11033:637::-;;;;;;;;;;;;;;;;-1:-1:-1;11033:637:3;;;;;;;;;;;;:::i;2300:925:56:-;;;:::i;2043:37:3:-;;;:::i;1438:30::-;;;:::i;1280:34::-;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1196:290:62;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;1196:290:62;;;;;;;;;;;;;;;;;:::i;1243:37:56:-;;;:::i;:::-;;;;-1:-1:-1;;;;;1243:37:56;;;;;;;;;;;;;;13353:2023:3;;;;;;;;;;;;;;;;-1:-1:-1;13353:2023:3;;;;;;;;-1:-1:-1;;;;;13353:2023:3;;;;;;;;;;;;;;;:::i;8408:254::-;;;;;;;;;;;;;;;;-1:-1:-1;8408:254:3;;:::i;1862:31::-;;;:::i;1422:217:57:-;;;:::i;1154:33:56:-;;;:::i;9057:171:3:-;;;;;;;;;;;;;;;;-1:-1:-1;9057:171:3;;;;:::i;2735:65::-;;;;;;;;;;;;;;;;-1:-1:-1;2735:65:3;;;;;;-1:-1:-1;;;;;2735:65:3;;:::i;219:29:57:-;;;:::i;2399:35:3:-;;;:::i;2520:52::-;;;;;;;;;;;;;;;;-1:-1:-1;2520:52:3;;:::i;:::-;;;;;;;;;;;;;;-1:-1:-1;;;;;2520:52:3;;;;;;;;;;;;;;;;;;;;;;;;;;;;8776:163;;;;;;;;;;;;;;;;-1:-1:-1;8776:163:3;;:::i;9743:103::-;;;;;;;;;;;;;;;;-1:-1:-1;9743:103:3;;;;:::i;1323:27::-;;;:::i;15778:397::-;;;;;;;;;;;;;;;;-1:-1:-1;15778:397:3;;;;;;-1:-1:-1;;;;;15778:397:3;;:::i;7897:143::-;;;;;;;;;;;;;;;;-1:-1:-1;7897:143:3;;:::i;3304:137:56:-;;;:::i;8152:158:3:-;;;;;;;;;;;;;;;;-1:-1:-1;8152:158:3;;:::i;2140:31::-;;;:::i;:::-;;;;;;;;;;;;;;;;;;;255:23:57;;;:::i;9460:120:3:-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;9460:120:3;;;;;;;;;;:::i;2609:50::-;;;;;;;;;;;;;;;;-1:-1:-1;2609:50:3;;:::i;10017:101::-;;;;;;;;;;;;;;;;-1:-1:-1;10017:101:3;;;;:::i;1164:167:57:-;;;;;;;;;;;;;;;;-1:-1:-1;1164:167:57;-1:-1:-1;;;;;1164:167:57;;:::i;1767:31:3:-;;;:::i;2305:36::-;;;:::i;2243:33::-;;;:::i;10400:302::-;726:12:57;:10;:12::i;:::-;10474:32:3::1;10526:28;-1:-1:-1::0;;;10526:9:3::1;:28::i;:::-;10474:81;;10568:43;10594:15;10568:17;:43::i;:::-;10622:44;::::0;;-1:-1:-1;;;10622:44:3;;1313:1:::1;10622:44:::0;;::::1;::::0;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;10622:23:3;::::1;::::0;::::1;::::0;10655:10;;10622:44;;;;;;::::1;::::0;;::::1;::::0;::::1;::::0;;;-1:-1:-1;10622:44:3::1;;;;;;;::::0;;::::1;::::0;;;::::1;::::0;::::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;10677:17;:15;:17::i;:::-;749:1:57;10400:302:3::0;:::o;3655:224:56:-;726:12:57;:10;:12::i;:::-;3815:26:56::1;:56:::0;;;::::1;;-1:-1:-1::0;;;3815:56:56::1;-1:-1:-1::0;;;;3815:56:56;;::::1;::::0;;;::::1;::::0;;3655:224::o;1675:28:3:-;;;;:::o;16338:392::-;16390:7;16499:24;16526:82;16544:63;16590:16;;16545:39;16564:19;;16546:12;16545:18;;:39;;;;:::i;:::-;16544:45;;:63::i;:::-;16526:13;;;:17;:82::i;:::-;16499:109;;16642:12;;16623:16;:31;16619:69;;;-1:-1:-1;;16676:12:3;;16669:19;;16619:69;16706:16;-1:-1:-1;16338:392:3;;:::o;1949:34::-;;;;:::o;16898:422::-;16953:7;17068:27;17098:88;17119:66;17168:16;;17120:42;17139:22;;17121:12;17120:18;;:42;;;;:::i;17119:66::-;17098:16;;;:20;:88::i;:::-;17068:118;;17223:15;;17201:19;:37;17197:78;;;-1:-1:-1;;17260:15:3;;17253:22;;1555:23;;;;:::o;2856:42::-;;;;;;;;;;;;;;;:::o;1333:38:56:-;;;-1:-1:-1;;;1333:38:56;;;;;:::o;12106:684:3:-;7293:20;:18;:20::i;:::-;12275:24:::1;12302:21;:19;:21::i;:::-;12275:48;;12421:8;;12410:7;:19;;:50;;;;;12444:16;12433:7;:27;;12410:50;12402:82;;;::::0;;-1:-1:-1;;;12402:82:3;;::::1;;::::0;::::1;::::0;::::1;::::0;;;;-1:-1:-1;;;12402:82:3;;;;;;;;;;;;;::::1;;12497:19;12508:7;12497:10;:19::i;:::-;12602:29;:16:::0;12623:7;12602:20:::1;:29::i;:::-;12586:13;:45:::0;12664:12:::1;12642:19;:34:::0;12727:55:::1;::::0;;;;;::::1;::::0;::::1;::::0;;;;;;;;;;;12764:3;;12737:10:::1;::::0;12727:55:::1;::::0;;;;;;;::::1;7324:1;12106:684:::0;;;;:::o;11033:637::-;7293:20;:18;:20::i;:::-;11180:24:::1;11207:21;:19;:21::i;:::-;11180:48;;11290:8;;11279:7;:19;;:50;;;;;11313:16;11302:7;:27;;11279:50;11271:82;;;::::0;;-1:-1:-1;;;11271:82:3;;::::1;;::::0;::::1;::::0;::::1;::::0;;;;-1:-1:-1;;;11271:82:3;;;;;;;;;;;;;::::1;;11366:19;11377:7;11366:10;:19::i;:::-;11471:29;:16:::0;11492:7;11471:20:::1;:29::i;:::-;11455:13;:45:::0;11533:12:::1;11511:19;:34:::0;11609:53:::1;::::0;;;;;::::1;::::0;::::1;::::0;;;-1:-1:-1;11609:53:3;;;;;;11646:3;;11619:10:::1;::::0;11609:53:::1;::::0;;;;;;;::::1;7324:1;11033:637:::0;;;:::o;2300:925:56:-;2417:5;;-1:-1:-1;;;;;2417:5:56;2403:10;:19;;:50;;-1:-1:-1;2427:26:56;;-1:-1:-1;;;2427:26:56;;;;2426:27;2403:50;2395:80;;;;;-1:-1:-1;;;2395:80:56;;;;;;;;;;;;-1:-1:-1;;;2395:80:56;;;;;;;;;;;;;;;2530:29;2580:28;-1:-1:-1;;;2580:9:56;:28::i;:::-;2721:8;;2530:79;;-1:-1:-1;;;;;;2706:23:56;;;2721:8;;2706:23;;;;:61;;-1:-1:-1;;;;;;2733:34:56;;;;2706:61;2698:94;;;;;-1:-1:-1;;;2698:94:56;;;;;;;;;;;;-1:-1:-1;;;2698:94:56;;;;;;;;;;;;;;;2959:1;-1:-1:-1;;;;;2907:54:56;:11;-1:-1:-1;;;;;2907:21:56;;-1:-1:-1;;;2907:40:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;2907:40:56;-1:-1:-1;;;;;2907:54:56;;;2899:87;;;;;-1:-1:-1;;;2899:87:56;;;;;;;;;;;;-1:-1:-1;;;2899:87:56;;;;;;;;;;;;;;;3093:8;;;3078:12;:23;;-1:-1:-1;;;;;3093:8:56;;;-1:-1:-1;;;;;;3078:23:56;;;;;;;3195:22;;;;;;;;;;;2300:925::o;2043:37:3:-;;;;:::o;1438:30::-;;;;:::o;1280:34::-;1313:1;1280:34;:::o;1196:290:62:-;726:12:57;:10;:12::i;:::-;1370:6:62::1;594:23:64;608:8;594:13;:23::i;:::-;1401:3:62::2;594:23:64;608:8;594:13;:23::i;:::-;1423:3:62::3;948:18:64;957:8;948;:18::i;:::-;1444:34:62::4;1457:6;1465:3;1470:7;1444:12;:34::i;:::-;628:1:64::3;::::2;749::57::1;1196:290:62::0;;;:::o;1243:37:56:-;;;-1:-1:-1;;;;;1243:37:56;;:::o;13353:2023:3:-;6989:15;:13;:15::i;:::-;7594:19:::1;:17;:19::i;:::-;13601:3:::2;594:23:64;608:8;594:13;:23::i;:::-;13631:7:3::3;252:24:64;269:6;252:16;:24::i;:::-;13748:18:3::4;::::0;;;:11:::4;:18;::::0;;;;;;;13767:10:::4;13748:30:::0;;;;;;;;::::4;;13747:31;13739:64;;;::::0;;-1:-1:-1;;;13739:64:3;;::::4;;::::0;::::4;::::0;::::4;::::0;;;;-1:-1:-1;;;13739:64:3;;;;;;;;;;;;;::::4;;13849:18;::::0;;;:11:::4;:18;::::0;;;;;;;13868:10:::4;13849:30:::0;;;;;;;:37;;-1:-1:-1;;13849:37:3::4;13882:4;13849:37;::::0;;13925:19;;;:12:::4;:19:::0;;;;;14038:16:::4;::::0;::::4;::::0;-1:-1:-1;;;14038:16:3;::::4;13849:37;14038:16;14034:756;;14076:6;::::0;::::4;:12:::0;;-1:-1:-1;;;;;;14076:12:3::4;-1:-1:-1::0;;;;;14076:12:3;::::4;;::::0;;14103:20;;;-1:-1:-1;14138:18:3;::::4;:36:::0;;;14195:17;;14191:257:::4;;14318:28;::::0;;;:14:::4;:28;::::0;;;;;:33;14310:67:::4;;;::::0;;-1:-1:-1;;;14310:67:3;;::::4;;::::0;::::4;::::0;::::4;::::0;;;;-1:-1:-1;;;14310:67:3;;;;;;;;;;;;;::::4;;14396:28;::::0;;;:14:::4;:28;::::0;;;;:36;;;14191:257:::4;14034:756;;;14551:6;::::0;::::4;::::0;-1:-1:-1;;;;;14551:13:3;;::::4;:6:::0;::::4;:13;:38:::0;::::4;;;-1:-1:-1::0;14568:10:3;;:21;::::4;14551:38;:79;;;;;14615:15;14593:3;:18;;;:37;14551:79;14543:107;;;::::0;;-1:-1:-1;;;14543:107:3;;::::4;;::::0;::::4;::::0;::::4;::::0;;;;-1:-1:-1;;;14543:107:3;;;;;;;;;;;;;::::4;;14671:17:::0;;14667:111:::4;;14715:28;::::0;;;:14:::4;:28;::::0;;;;;:37;::::4;14707:71;;;::::0;;-1:-1:-1;;;14707:71:3;;::::4;;::::0;::::4;::::0;::::4;::::0;;;;-1:-1:-1;;;14707:71:3;;;;;;;;;;;;;::::4;;14846:16;::::0;::::4;:18:::0;;::::4;;-1:-1:-1::0;;;14846:18:3;;::::4;::::0;::::4;::::0;;;::::4;;;-1:-1:-1::0;;;;14846:18:3;;::::4;;::::0;;14882:72:::4;::::0;;;;;::::4;::::0;::::4;::::0;;;-1:-1:-1;;;;;14882:72:3;::::4;::::0;;;;;;;;;;;;;;;;;;14891:10:::4;::::0;14882:72:::4;::::0;;;;;;;;::::4;15051:18;::::0;15031:16:::4;::::0;::::4;::::0;15051:18:::4;::::0;;::::4;-1:-1:-1::0;;;15031:16:3;;::::4;::::0;;::::4;:38;15027:342;;15095:19;::::0;;;:12:::4;:19;::::0;;;;:29:::4;;::::0;-1:-1:-1;;;15095:29:3;::::4;;;15094:30;15086:67;;;::::0;;-1:-1:-1;;;15086:67:3;;::::4;;::::0;::::4;::::0;::::4;::::0;;;;::::4;::::0;;;;;;;;;;;;;::::4;;15219:19;::::0;;;:12:::4;:19;::::0;;;;;;;;:29:::4;;:36:::0;;-1:-1:-1;;;;15219:36:3::4;-1:-1:-1::0;;;15219:36:3::4;::::0;;15277;;-1:-1:-1;;;;;15277:36:3;::::4;::::0;;;;::::4;::::0;;;;;::::4;::::0;;;;;;;;;::::4;15330:27;15344:3;15349:7;15330:13;:27::i;:::-;287:1:64;628::::3;7624::3::2;13353:2023:::0;;;;;:::o;8408:254::-;726:12:57;:10;:12::i;:::-;8481:9:3::1;252:24:64;269:6;252:16;:24::i;:::-;8551:12:3::2;;8538:9;:25;;:57;;;;;8580:15;;8567:9;:28;;8538:57;8530:91;;;::::0;;-1:-1:-1;;;8530:91:3;;::::2;;::::0;::::2;::::0;::::2;::::0;;;;-1:-1:-1;;;8530:91:3;;;;;;;;;;;;;::::2;;-1:-1:-1::0;8634:8:3::2;:20:::0;8408:254::o;1862:31::-;;;;:::o;1422:217:57:-;1498:8;;-1:-1:-1;;;;;1498:8:57;1484:10;:22;1476:52;;;;;-1:-1:-1;;;1476:52:57;;;;;;;;;;;;-1:-1:-1;;;1476:52:57;;;;;;;;;;;;;;;1563:8;;;1556:5;;1544:28;;-1:-1:-1;;;;;1563:8:57;;;;1556:5;;;;1544:28;;;1591:8;;;;1583:16;;-1:-1:-1;;;;;;1583:16:57;;;-1:-1:-1;;;;;1591:8:57;;1583:16;;;;1610:21;;;1422:217::o;1154:33:56:-;;;-1:-1:-1;;;;;1154:33:56;;:::o;9057:171:3:-;726:12:57;:10;:12::i;:::-;9148:19:3::1;200:96:64;;252:24;269:6;252:16;:24::i;:::-;-1:-1:-1::0;9180:18:3::2;:40:::0;;-1:-1:-1;;9180:40:3::2;;::::0;;;::::2;::::0;;;::::2;::::0;;9057:171::o;2735:65::-;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;219:29:57:-;;;-1:-1:-1;;;;;219:29:57;;:::o;2399:35:3:-;;;-1:-1:-1;;;2399:35:3;;;;;:::o;2520:52::-;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;2520:52:3;;;;-1:-1:-1;;;2520:52:3;;;;;-1:-1:-1;;;2520:52:3;;;;:::o;8776:163::-;726:12:57;:10;:12::i;:::-;8865:17:3::1;252:24:64;269:6;252:16;:24::i;:::-;-1:-1:-1::0;8895:16:3::2;:36:::0;8776:163::o;9743:103::-;726:12:57;:10;:12::i;:::-;9811:17:3::1;:27:::0;;;::::1;;-1:-1:-1::0;;;9811:27:3::1;-1:-1:-1::0;;;;9811:27:3;;::::1;::::0;;;::::1;::::0;;9743:103::o;1323:27::-;;;;:::o;15778:397::-;15872:7;15939:30;;:::i;:::-;-1:-1:-1;15972:42:3;15985:28;;;:14;:28;;;;;;;;;15972:42;;:12;:42;;;;;;15939:75;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;15939:75:3;;;;;;;;;;-1:-1:-1;;;15939:75:3;;;;;;;;-1:-1:-1;;;15939:75:3;;;;;;;;;;;;;;16087:22;;;;16079:50;;;;;-1:-1:-1;;;16079:50:3;;;;;;;;;;;;-1:-1:-1;;;16079:50:3;;;;;;;;;;;;;;;16149:18;;-1:-1:-1;15778:397:3;;;;;:::o;7897:143::-;726:12:57;:10;:12::i;:::-;7978:13:3::1;252:24:64;269:6;252:16;:24::i;:::-;-1:-1:-1::0;8004:12:3::2;:28:::0;7897:143::o;3304:137:56:-;726:12:57;:10;:12::i;:::-;3421::56::1;::::0;3410:8:::1;:23:::0;;-1:-1:-1;;;;;;3410:23:56::1;-1:-1:-1::0;;;;;3421:12:56;;::::1;3410:23:::0;;;::::1;::::0;;3304:137::o;8152:158:3:-;726:12:57;:10;:12::i;:::-;8239:16:3::1;252:24:64;269:6;252:16;:24::i;:::-;-1:-1:-1::0;8268:15:3::2;:34:::0;8152:158::o;2140:31::-;;;;;;:::o;255:23:57:-;;;-1:-1:-1;;;;;255:23:57;;:::o;9460:120:3:-;726:12:57;:10;:12::i;:::-;-1:-1:-1;;;;;9542:20:3;;;::::1;;::::0;;;:9:::1;:20;::::0;;;;:30;;-1:-1:-1;;9542:30:3::1;::::0;::::1;;::::0;;;::::1;::::0;;9460:120::o;2609:50::-;;;;;;;;;;;;;:::o;10017:101::-;726:12:57;:10;:12::i;:::-;10084:16:3::1;:26:::0;;;::::1;;-1:-1:-1::0;;;10084:26:3::1;-1:-1:-1::0;;;;10084:26:3;;::::1;::::0;;;::::1;::::0;;10017:101::o;1164:167:57:-;726:12;:10;:12::i;:::-;1268:5:::1;::::0;-1:-1:-1;;;;;1255:18:57;;::::1;1268:5:::0;::::1;1255:18;;1247:45;;;::::0;;-1:-1:-1;;;1247:45:57;;::::1;;::::0;::::1;::::0;::::1;::::0;;;;-1:-1:-1;;;1247:45:57;;;;;;;;;;;;;::::1;;1303:8;:20:::0;;-1:-1:-1;;;;;;1303:20:57::1;-1:-1:-1::0;;;;;1303:20:57;;;::::1;::::0;;;::::1;::::0;;1164:167::o;1767:31:3:-;;;;:::o;2305:36::-;;;-1:-1:-1;;;2305:36:3;;;;;:::o;2243:33::-;;;;;;-1:-1:-1;;;;;2243:33:3;;:::o;813:104:57:-;882:5;;-1:-1:-1;;;;;882:5:57;868:10;:19;860:49;;;;;-1:-1:-1;;;860:49:57;;;;;;;;;;;;-1:-1:-1;;;860:49:57;;;;;;;;;;;;;;;813:104::o;4077:133:56:-;4169:8;;:33;;;-1:-1:-1;;;4169:33:56;;;;;;;;;;4142:7;;-1:-1:-1;;;;;4169:8:56;;:18;;:33;;;;;;;;;;;;;;:8;:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;4169:33:56;;4077:133;-1:-1:-1;;4077:133:56:o;778:147:60:-;838:7;872:2;866;:8;;858:34;;;;;-1:-1:-1;;;858:34:60;;;;;;;;;;;;-1:-1:-1;;;858:34:60;;;;;;;;;;;;;;;-1:-1:-1;910:7:60;;;778:147::o;1149:250::-;1209:7;1262;1258:34;;-1:-1:-1;1291:1:60;1284:8;;1258:34;1317:7;;;1322:2;1317;:7;:2;1343:6;;;;;:12;1335:37;;;;;-1:-1:-1;;;1335:37:60;;;;;;;;;;;;-1:-1:-1;;;1335:37:60;;;;;;;;;;;;;;;1390:1;1149:250;-1:-1:-1;;;1149:250:60:o;386:169::-;446:7;478;;;504;;;;496:32;;;;;-1:-1:-1;;;496:32:60;;;;;;;;;;;;-1:-1:-1;;;496:32:60;;;;;;;;;;;;;;7388:105:3;7451:17;;-1:-1:-1;;;7451:17:3;;;;7443:42;;;;;-1:-1:-1;;;7443:42:3;;;;;;;;;;;;-1:-1:-1;;;7443:42:3;;;;;;;;;;;;;;17511:170;17584:5;;17567:59;;17584:5;;;-1:-1:-1;;;;;17584:5:3;17591:10;17611:4;17618:7;17567:16;:59::i;:::-;17642:31;;;;;;;;17653:10;;17642:31;;;;;;;;;;17511:170;:::o;692:128:64:-;-1:-1:-1;;;;;766:22:64;;758:54;;;;;-1:-1:-1;;;758:54:64;;;;;;;;;;;;-1:-1:-1;;;758:54:64;;;;;;;;;;;;;;;692:128;:::o;1041:126::-;-1:-1:-1;;;;;1110:25:64;;1130:4;1110:25;;1102:57;;;;;-1:-1:-1;;;1102:57:64;;;;;;;;;;;;-1:-1:-1;;;1102:57:64;;;;;;;;;;;;;;1485:312:61;1631:59;;;-1:-1:-1;;;;;1631:59:61;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;1631:59:61;-1:-1:-1;;;1631:59:61;;;1610:81;;;;1575:12;;1589:17;;1610:20;;;;1631:59;1610:81;;;1631:59;1610:81;;1631:59;1610:81;;;;;;;;;;-1:-1:-1;;1610:81:61;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1574:117;;;;1709:7;:57;;;;-1:-1:-1;1721:11:61;;:16;;:44;;;1752:4;1741:24;;;;;;;;;;;;;;;-1:-1:-1;1741:24:61;1721:44;1701:89;;;;;-1:-1:-1;;;1701:89:61;;;;;;;;;;;;-1:-1:-1;;;1701:89:61;;;;;;;;;;;;;;;1485:312;;;;;:::o;7079:109:3:-;7147:10;7137:21;;;;:9;:21;;;;;;;;7129:51;;;;;-1:-1:-1;;;7129:51:3;;;;;;;;;;;;-1:-1:-1;;;7129:51:3;;;;;;;;;;;;;;7688:103;7750:16;;-1:-1:-1;;;7750:16:3;;;;7742:41;;;;;-1:-1:-1;;;7742:41:3;;;;;;;;;;;;-1:-1:-1;;;7742:41:3;;;;;;;;;;;;;;351:112:64;435:1;426:6;:10;418:37;;;;;-1:-1:-1;;;418:37:64;;;;;;;;;;;;-1:-1:-1;;;418:37:64;;;;;;;;;;;;;;17899:591:3;18013:27;18043:24;:22;:24::i;:::-;18013:54;;18099:8;;18088:7;:19;;:53;;;;;18122:19;18111:7;:30;;18088:53;18080:85;;;;;-1:-1:-1;;;18080:85:3;;;;;;;;;;;;-1:-1:-1;;;18080:85:3;;;;;;;;;;;;;;;18260:32;:19;18284:7;18260:23;:32::i;:::-;18241:16;:51;18328:12;18303:22;:37;18417:5;;18404:33;;18417:5;;;-1:-1:-1;;;;;18417:5:3;18424:3;18429:7;18404:12;:33::i;:::-;18455:27;;;;;;;;-1:-1:-1;;;;;18455:27:3;;;;;;;;;;;;;17899:591;;;:::o;2190:348:61:-;2355:71;;;-1:-1:-1;;;;;2355:71:61;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;2355:71:61;-1:-1:-1;;;2355:71:61;;;2334:93;;;;2299:12;;2313:17;;2334:20;;;;2355:71;2334:93;;;2355:71;2334:93;;2355:71;2334:93;;;;;;;;;;-1:-1:-1;;2334:93:61;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2298:129;;;;2445:7;:57;;;;-1:-1:-1;2457:11:61;;:16;;:44;;;2488:4;2477:24;;;;;;;;;;;;;;;-1:-1:-1;2477:24:61;2457:44;2437:94;;;;;-1:-1:-1;;;2437:94:61;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o",
+ "source": "// SPDX-License-Identifier: SEE LICENSE IN LICENSE\r\npragma solidity 0.6.12;\r\nimport \"./interfaces/IBancorXUpgrader.sol\";\r\nimport \"./interfaces/IBancorX.sol\";\r\nimport \"../utility/ContractRegistryClient.sol\";\r\nimport \"../utility/SafeMath.sol\";\r\nimport \"../utility/TokenHandler.sol\";\r\nimport \"../utility/TokenHolder.sol\";\r\n\r\n/**\r\n * @dev The BancorX contract allows cross chain token transfers.\r\n *\r\n * There are two processes that take place in the contract -\r\n * - Initiate a cross chain transfer to a target blockchain (locks tokens from the caller account on Ethereum)\r\n * - Report a cross chain transfer initiated on a source blockchain (releases tokens to an account on Ethereum)\r\n *\r\n * Reporting cross chain transfers works similar to standard multisig contracts, meaning that multiple\r\n * callers are required to report a transfer before tokens are released to the target account.\r\n*/\r\ncontract BancorX is IBancorX, TokenHandler, TokenHolder, ContractRegistryClient {\r\n using SafeMath for uint256;\r\n\r\n // represents a transaction on another blockchain where tokens were destroyed/locked\r\n struct Transaction {\r\n uint256 amount;\r\n bytes32 fromBlockchain;\r\n address to;\r\n uint8 numOfReports;\r\n bool completed;\r\n }\r\n\r\n uint16 public constant version = 4;\r\n\r\n uint256 public maxLockLimit; // the maximum amount of tokens that can be locked in one transaction\r\n uint256 public maxReleaseLimit; // the maximum amount of tokens that can be released in one transaction\r\n uint256 public minLimit; // the minimum amount of tokens that can be transferred in one transaction\r\n uint256 public prevLockLimit; // the lock limit *after* the last transaction\r\n uint256 public prevReleaseLimit; // the release limit *after* the last transaction\r\n uint256 public limitIncPerBlock; // how much the limit increases per block\r\n uint256 public prevLockBlockNumber; // the block number of the last lock transaction\r\n uint256 public prevReleaseBlockNumber; // the block number of the last release transaction\r\n uint8 public minRequiredReports; // minimum number of required reports to release tokens\r\n\r\n IERC20Token public override token; // erc20 token\r\n\r\n bool public xTransfersEnabled = true; // true if x transfers are enabled, false if not\r\n bool public reportingEnabled = true; // true if reporting is enabled, false if not\r\n\r\n // txId -> Transaction\r\n mapping (uint256 => Transaction) public transactions;\r\n\r\n // xTransferId -> txId\r\n mapping (uint256 => uint256) public transactionIds;\r\n\r\n // txId -> reporter -> true if reporter already reported txId\r\n mapping (uint256 => mapping (address => bool)) public reportedTxs;\r\n\r\n // address -> true if address is reporter\r\n mapping (address => bool) public reporters;\r\n\r\n /**\r\n * @dev triggered when tokens are locked in smart contract\r\n *\r\n * @param _from wallet address that the tokens are locked from\r\n * @param _amount amount locked\r\n */\r\n event TokensLock(\r\n address indexed _from,\r\n uint256 _amount\r\n );\r\n\r\n /**\r\n * @dev triggered when tokens are released by the smart contract\r\n *\r\n * @param _to wallet address that the tokens are released to\r\n * @param _amount amount released\r\n */\r\n event TokensRelease(\r\n address indexed _to,\r\n uint256 _amount\r\n );\r\n\r\n /**\r\n * @dev triggered when xTransfer is successfully called\r\n *\r\n * @param _from wallet address that initiated the xtransfer\r\n * @param _toBlockchain target blockchain\r\n * @param _to target wallet\r\n * @param _amount transfer amount\r\n * @param _id xtransfer id\r\n */\r\n event XTransfer(\r\n address indexed _from,\r\n bytes32 _toBlockchain,\r\n bytes32 indexed _to,\r\n uint256 _amount,\r\n uint256 _id\r\n );\r\n\r\n /**\r\n * @dev triggered when report is successfully submitted\r\n *\r\n * @param _reporter reporter wallet\r\n * @param _fromBlockchain source blockchain\r\n * @param _txId tx id on the source blockchain\r\n * @param _to target wallet\r\n * @param _amount transfer amount\r\n * @param _xTransferId xtransfer id\r\n */\r\n event TxReport(\r\n address indexed _reporter,\r\n bytes32 _fromBlockchain,\r\n uint256 _txId,\r\n address _to,\r\n uint256 _amount,\r\n uint256 _xTransferId\r\n );\r\n\r\n /**\r\n * @dev triggered when final report is successfully submitted\r\n *\r\n * @param _to target wallet\r\n * @param _id xtransfer id\r\n */\r\n event XTransferComplete(\r\n address _to,\r\n uint256 _id\r\n );\r\n\r\n /**\r\n * @dev initializes a new BancorX instance\r\n *\r\n * @param _maxLockLimit maximum amount of tokens that can be locked in one transaction\r\n * @param _maxReleaseLimit maximum amount of tokens that can be released in one transaction\r\n * @param _minLimit minimum amount of tokens that can be transferred in one transaction\r\n * @param _limitIncPerBlock how much the limit increases per block\r\n * @param _minRequiredReports minimum number of reporters to report transaction before tokens can be released\r\n * @param _registry address of contract registry\r\n * @param _token erc20 token\r\n */\r\n constructor(\r\n uint256 _maxLockLimit,\r\n uint256 _maxReleaseLimit,\r\n uint256 _minLimit,\r\n uint256 _limitIncPerBlock,\r\n uint8 _minRequiredReports,\r\n IContractRegistry _registry,\r\n IERC20Token _token\r\n ) ContractRegistryClient(_registry)\r\n public\r\n greaterThanZero(_maxLockLimit)\r\n greaterThanZero(_maxReleaseLimit)\r\n greaterThanZero(_minLimit)\r\n greaterThanZero(_limitIncPerBlock)\r\n greaterThanZero(_minRequiredReports)\r\n validAddress(address(_token))\r\n notThis(address(_token))\r\n {\r\n // validate input\r\n require(_minLimit <= _maxLockLimit && _minLimit <= _maxReleaseLimit, \"ERR_INVALID_MIN_LIMIT\");\r\n\r\n // the maximum limits, minimum limit, and limit increase per block\r\n maxLockLimit = _maxLockLimit;\r\n maxReleaseLimit = _maxReleaseLimit;\r\n minLimit = _minLimit;\r\n limitIncPerBlock = _limitIncPerBlock;\r\n minRequiredReports = _minRequiredReports;\r\n\r\n // previous limit is _maxLimit, and previous block number is current block number\r\n prevLockLimit = _maxLockLimit;\r\n prevReleaseLimit = _maxReleaseLimit;\r\n prevLockBlockNumber = block.number;\r\n prevReleaseBlockNumber = block.number;\r\n\r\n token = _token;\r\n }\r\n\r\n // validates that the caller is a reporter\r\n modifier reporterOnly {\r\n _reporterOnly();\r\n _;\r\n }\r\n\r\n // error message binary size optimization\r\n function _reporterOnly() internal view {\r\n require(reporters[msg.sender], \"ERR_ACCESS_DENIED\");\r\n }\r\n\r\n // allows execution only when x transfers are enabled\r\n modifier xTransfersAllowed {\r\n _xTransfersAllowed();\r\n _;\r\n }\r\n\r\n // error message binary size optimization\r\n function _xTransfersAllowed() internal view {\r\n require(xTransfersEnabled, \"ERR_DISABLED\");\r\n }\r\n\r\n // allows execution only when reporting is enabled\r\n modifier reportingAllowed {\r\n _reportingAllowed();\r\n _;\r\n }\r\n\r\n // error message binary size optimization\r\n function _reportingAllowed() internal view {\r\n require(reportingEnabled, \"ERR_DISABLED\");\r\n }\r\n\r\n /**\r\n * @dev setter\r\n *\r\n * @param _maxLockLimit new maxLockLimit\r\n */\r\n function setMaxLockLimit(uint256 _maxLockLimit) public ownerOnly greaterThanZero(_maxLockLimit) {\r\n maxLockLimit = _maxLockLimit;\r\n }\r\n\r\n /**\r\n * @dev setter\r\n *\r\n * @param _maxReleaseLimit new maxReleaseLimit\r\n */\r\n function setMaxReleaseLimit(uint256 _maxReleaseLimit) public ownerOnly greaterThanZero(_maxReleaseLimit) {\r\n maxReleaseLimit = _maxReleaseLimit;\r\n }\r\n\r\n /**\r\n * @dev setter\r\n *\r\n * @param _minLimit new minLimit\r\n */\r\n function setMinLimit(uint256 _minLimit) public ownerOnly greaterThanZero(_minLimit) {\r\n // validate input\r\n require(_minLimit <= maxLockLimit && _minLimit <= maxReleaseLimit, \"ERR_INVALID_MIN_LIMIT\");\r\n\r\n minLimit = _minLimit;\r\n }\r\n\r\n /**\r\n * @dev setter\r\n *\r\n * @param _limitIncPerBlock new limitIncPerBlock\r\n */\r\n function setLimitIncPerBlock(uint256 _limitIncPerBlock) public ownerOnly greaterThanZero(_limitIncPerBlock) {\r\n limitIncPerBlock = _limitIncPerBlock;\r\n }\r\n\r\n /**\r\n * @dev setter\r\n *\r\n * @param _minRequiredReports new minRequiredReports\r\n */\r\n function setMinRequiredReports(uint8 _minRequiredReports) public ownerOnly greaterThanZero(_minRequiredReports) {\r\n minRequiredReports = _minRequiredReports;\r\n }\r\n\r\n /**\r\n * @dev allows the owner to set/remove reporters\r\n *\r\n * @param _reporter reporter whos status is to be set\r\n * @param _active true if the reporter is approved, false otherwise\r\n */\r\n function setReporter(address _reporter, bool _active) public ownerOnly {\r\n reporters[_reporter] = _active;\r\n }\r\n\r\n /**\r\n * @dev allows the owner enable/disable the xTransfer method\r\n *\r\n * @param _enable true to enable, false to disable\r\n */\r\n function enableXTransfers(bool _enable) public ownerOnly {\r\n xTransfersEnabled = _enable;\r\n }\r\n\r\n /**\r\n * @dev allows the owner enable/disable the reportTransaction method\r\n *\r\n * @param _enable true to enable, false to disable\r\n */\r\n function enableReporting(bool _enable) public ownerOnly {\r\n reportingEnabled = _enable;\r\n }\r\n\r\n /**\r\n * @dev upgrades the contract to the latest version\r\n * can only be called by the owner\r\n * note that the owner needs to call acceptOwnership on the new contract after the upgrade\r\n *\r\n * @param _reporters new list of reporters\r\n */\r\n function upgrade(address[] memory _reporters) public ownerOnly {\r\n IBancorXUpgrader bancorXUpgrader = IBancorXUpgrader(addressOf(BANCOR_X_UPGRADER));\r\n\r\n transferOwnership(address(bancorXUpgrader));\r\n bancorXUpgrader.upgrade(version, _reporters);\r\n acceptOwnership();\r\n }\r\n\r\n /**\r\n * @dev claims tokens from msg.sender to be converted to tokens on another blockchain\r\n *\r\n * @param _toBlockchain blockchain on which tokens will be issued\r\n * @param _to address to send the tokens to\r\n * @param _amount the amount of tokens to transfer\r\n */\r\n function xTransfer(bytes32 _toBlockchain, bytes32 _to, uint256 _amount) public xTransfersAllowed {\r\n // get the current lock limit\r\n uint256 currentLockLimit = getCurrentLockLimit();\r\n\r\n // verify lock limit\r\n require(_amount >= minLimit && _amount <= currentLockLimit, \"ERR_AMOUNT_TOO_HIGH\");\r\n\r\n lockTokens(_amount);\r\n\r\n // set the previous lock limit and block number\r\n prevLockLimit = currentLockLimit.sub(_amount);\r\n prevLockBlockNumber = block.number;\r\n\r\n // emit XTransfer event with id of 0\r\n emit XTransfer(msg.sender, _toBlockchain, _to, _amount, 0);\r\n }\r\n\r\n /**\r\n * @dev claims tokens from msg.sender to be converted to tokens on another blockchain\r\n *\r\n * @param _toBlockchain blockchain on which tokens will be issued\r\n * @param _to address to send the tokens to\r\n * @param _amount the amount of tokens to transfer\r\n * @param _id pre-determined unique (if non zero) id which refers to this transaction\r\n */\r\n function xTransfer(bytes32 _toBlockchain, bytes32 _to, uint256 _amount, uint256 _id) public override xTransfersAllowed {\r\n // get the current lock limit\r\n uint256 currentLockLimit = getCurrentLockLimit();\r\n\r\n // require that; minLimit <= _amount <= currentLockLimit\r\n require(_amount >= minLimit && _amount <= currentLockLimit, \"ERR_AMOUNT_TOO_HIGH\");\r\n\r\n lockTokens(_amount);\r\n\r\n // set the previous lock limit and block number\r\n prevLockLimit = currentLockLimit.sub(_amount);\r\n prevLockBlockNumber = block.number;\r\n\r\n // emit XTransfer event\r\n emit XTransfer(msg.sender, _toBlockchain, _to, _amount, _id);\r\n }\r\n\r\n /**\r\n * @dev allows reporter to report transaction which occured on another blockchain\r\n *\r\n * @param _fromBlockchain blockchain in which tokens were destroyed\r\n * @param _txId transactionId of transaction thats being reported\r\n * @param _to address to receive tokens\r\n * @param _amount amount of tokens destroyed on another blockchain\r\n * @param _xTransferId unique (if non zero) pre-determined id (unlike _txId which is determined after the transactions been mined)\r\n */\r\n function reportTx(\r\n bytes32 _fromBlockchain,\r\n uint256 _txId,\r\n address _to,\r\n uint256 _amount,\r\n uint256 _xTransferId\r\n )\r\n public\r\n reporterOnly\r\n reportingAllowed\r\n validAddress(_to)\r\n greaterThanZero(_amount)\r\n {\r\n // require that the transaction has not been reported yet by the reporter\r\n require(!reportedTxs[_txId][msg.sender], \"ERR_ALREADY_REPORTED\");\r\n\r\n // set reported as true\r\n reportedTxs[_txId][msg.sender] = true;\r\n\r\n Transaction storage txn = transactions[_txId];\r\n\r\n // If the caller is the first reporter, set the transaction details\r\n if (txn.numOfReports == 0) {\r\n txn.to = _to;\r\n txn.amount = _amount;\r\n txn.fromBlockchain = _fromBlockchain;\r\n\r\n if (_xTransferId != 0) {\r\n // verify uniqueness of xTransfer id to prevent overwriting\r\n require(transactionIds[_xTransferId] == 0, \"ERR_TX_ALREADY_EXISTS\");\r\n transactionIds[_xTransferId] = _txId;\r\n }\r\n }\r\n else {\r\n // otherwise, verify transaction details\r\n require(txn.to == _to && txn.amount == _amount && txn.fromBlockchain == _fromBlockchain, \"ERR_TX_MISMATCH\");\r\n\r\n if (_xTransferId != 0)\r\n require(transactionIds[_xTransferId] == _txId, \"ERR_TX_ALREADY_EXISTS\");\r\n }\r\n\r\n // increment the number of reports\r\n txn.numOfReports++;\r\n\r\n emit TxReport(msg.sender, _fromBlockchain, _txId, _to, _amount, _xTransferId);\r\n\r\n // if theres enough reports, try to release tokens\r\n if (txn.numOfReports >= minRequiredReports) {\r\n require(!transactions[_txId].completed, \"ERR_TX_ALREADY_COMPLETED\");\r\n\r\n // set the transaction as completed\r\n transactions[_txId].completed = true;\r\n\r\n emit XTransferComplete(_to, _xTransferId);\r\n\r\n releaseTokens(_to, _amount);\r\n }\r\n }\r\n\r\n /**\r\n * @dev gets x transfer amount by xTransferId (not txId)\r\n *\r\n * @param _xTransferId unique (if non zero) pre-determined id (unlike _txId which is determined after the transactions been broadcasted)\r\n * @param _for address corresponding to xTransferId\r\n *\r\n * @return amount that was sent in xTransfer corresponding to _xTransferId\r\n */\r\n function getXTransferAmount(uint256 _xTransferId, address _for) public view override returns (uint256) {\r\n // xTransferId -> txId -> Transaction\r\n Transaction memory transaction = transactions[transactionIds[_xTransferId]];\r\n\r\n // verify that the xTransferId is for _for\r\n require(transaction.to == _for, \"ERR_TX_MISMATCH\");\r\n\r\n return transaction.amount;\r\n }\r\n\r\n /**\r\n * @dev method for calculating current lock limit\r\n *\r\n * @return the current maximum limit of tokens that can be locked\r\n */\r\n function getCurrentLockLimit() public view returns (uint256) {\r\n // prevLockLimit + ((currBlockNumber - prevLockBlockNumber) * limitIncPerBlock)\r\n uint256 currentLockLimit = prevLockLimit.add(((block.number).sub(prevLockBlockNumber)).mul(limitIncPerBlock));\r\n if (currentLockLimit > maxLockLimit)\r\n return maxLockLimit;\r\n return currentLockLimit;\r\n }\r\n\r\n /**\r\n * @dev method for calculating current release limit\r\n *\r\n * @return the current maximum limit of tokens that can be released\r\n */\r\n function getCurrentReleaseLimit() public view returns (uint256) {\r\n // prevReleaseLimit + ((currBlockNumber - prevReleaseBlockNumber) * limitIncPerBlock)\r\n uint256 currentReleaseLimit = prevReleaseLimit.add(((block.number).sub(prevReleaseBlockNumber)).mul(limitIncPerBlock));\r\n if (currentReleaseLimit > maxReleaseLimit)\r\n return maxReleaseLimit;\r\n return currentReleaseLimit;\r\n }\r\n\r\n /**\r\n * @dev claims and locks tokens from msg.sender to be converted to tokens on another blockchain\r\n *\r\n * @param _amount the amount of tokens to lock\r\n */\r\n function lockTokens(uint256 _amount) private {\r\n safeTransferFrom(token, msg.sender, address(this), _amount);\r\n emit TokensLock(msg.sender, _amount);\r\n }\r\n\r\n /**\r\n * @dev private method to release tokens held by the contract\r\n *\r\n * @param _to the address to release tokens to\r\n * @param _amount the amount of tokens to release\r\n */\r\n function releaseTokens(address _to, uint256 _amount) private {\r\n // get the current release limit\r\n uint256 currentReleaseLimit = getCurrentReleaseLimit();\r\n\r\n require(_amount >= minLimit && _amount <= currentReleaseLimit, \"ERR_AMOUNT_TOO_HIGH\");\r\n\r\n // update the previous release limit and block number\r\n prevReleaseLimit = currentReleaseLimit.sub(_amount);\r\n prevReleaseBlockNumber = block.number;\r\n\r\n // no need to require, reverts on failure\r\n safeTransfer(token, _to, _amount);\r\n\r\n emit TokensRelease(_to, _amount);\r\n }\r\n}\r\n",
+ "sourcePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/bancorx/BancorX.sol",
+ "ast": {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/bancorx/BancorX.sol",
+ "exportedSymbols": {
+ "BancorX": [
+ 3447
+ ]
+ },
+ "id": 3448,
+ "license": "SEE LICENSE IN LICENSE",
+ "nodeType": "SourceUnit",
+ "nodes": [
+ {
+ "id": 2548,
+ "literals": [
+ "solidity",
+ "0.6",
+ ".12"
+ ],
+ "nodeType": "PragmaDirective",
+ "src": "52:23:3"
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/bancorx/interfaces/IBancorXUpgrader.sol",
+ "file": "./interfaces/IBancorXUpgrader.sol",
+ "id": 2549,
+ "nodeType": "ImportDirective",
+ "scope": 3448,
+ "sourceUnit": 3563,
+ "src": "77:43:3",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/bancorx/interfaces/IBancorX.sol",
+ "file": "./interfaces/IBancorX.sol",
+ "id": 2550,
+ "nodeType": "ImportDirective",
+ "scope": 3448,
+ "sourceUnit": 3552,
+ "src": "122:35:3",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/ContractRegistryClient.sol",
+ "file": "../utility/ContractRegistryClient.sol",
+ "id": 2551,
+ "nodeType": "ImportDirective",
+ "scope": 3448,
+ "sourceUnit": 21720,
+ "src": "159:47:3",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/SafeMath.sol",
+ "file": "../utility/SafeMath.sol",
+ "id": 2552,
+ "nodeType": "ImportDirective",
+ "scope": 3448,
+ "sourceUnit": 22355,
+ "src": "208:33:3",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/TokenHandler.sol",
+ "file": "../utility/TokenHandler.sol",
+ "id": 2553,
+ "nodeType": "ImportDirective",
+ "scope": 3448,
+ "sourceUnit": 22527,
+ "src": "243:37:3",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/TokenHolder.sol",
+ "file": "../utility/TokenHolder.sol",
+ "id": 2554,
+ "nodeType": "ImportDirective",
+ "scope": 3448,
+ "sourceUnit": 22576,
+ "src": "282:36:3",
+ "symbolAliases": [],
+ "unitAlias": ""
+ },
+ {
+ "abstract": false,
+ "baseContracts": [
+ {
+ "arguments": null,
+ "baseName": {
+ "contractScope": null,
+ "id": 2556,
+ "name": "IBancorX",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 3551,
+ "src": "920:8:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IBancorX_$3551",
+ "typeString": "contract IBancorX"
+ }
+ },
+ "id": 2557,
+ "nodeType": "InheritanceSpecifier",
+ "src": "920:8:3"
+ },
+ {
+ "arguments": null,
+ "baseName": {
+ "contractScope": null,
+ "id": 2558,
+ "name": "TokenHandler",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 22526,
+ "src": "930:12:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_TokenHandler_$22526",
+ "typeString": "contract TokenHandler"
+ }
+ },
+ "id": 2559,
+ "nodeType": "InheritanceSpecifier",
+ "src": "930:12:3"
+ },
+ {
+ "arguments": null,
+ "baseName": {
+ "contractScope": null,
+ "id": 2560,
+ "name": "TokenHolder",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 22575,
+ "src": "944:11:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_TokenHolder_$22575",
+ "typeString": "contract TokenHolder"
+ }
+ },
+ "id": 2561,
+ "nodeType": "InheritanceSpecifier",
+ "src": "944:11:3"
+ },
+ {
+ "arguments": null,
+ "baseName": {
+ "contractScope": null,
+ "id": 2562,
+ "name": "ContractRegistryClient",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21719,
+ "src": "957:22:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_ContractRegistryClient_$21719",
+ "typeString": "contract ContractRegistryClient"
+ }
+ },
+ "id": 2563,
+ "nodeType": "InheritanceSpecifier",
+ "src": "957:22:3"
+ }
+ ],
+ "contractDependencies": [
+ 3551,
+ 21719,
+ 21818,
+ 22526,
+ 22575,
+ 22661,
+ 22847,
+ 22907
+ ],
+ "contractKind": "contract",
+ "documentation": {
+ "id": 2555,
+ "nodeType": "StructuredDocumentation",
+ "src": "322:576:3",
+ "text": " @dev The BancorX contract allows cross chain token transfers.\n There are two processes that take place in the contract -\n - Initiate a cross chain transfer to a target blockchain (locks tokens from the caller account on Ethereum)\n - Report a cross chain transfer initiated on a source blockchain (releases tokens to an account on Ethereum)\n Reporting cross chain transfers works similar to standard multisig contracts, meaning that multiple\n callers are required to report a transfer before tokens are released to the target account."
+ },
+ "fullyImplemented": true,
+ "id": 3447,
+ "linearizedBaseContracts": [
+ 3447,
+ 21719,
+ 22575,
+ 22661,
+ 21818,
+ 22526,
+ 22907,
+ 22847,
+ 3551
+ ],
+ "name": "BancorX",
+ "nodeType": "ContractDefinition",
+ "nodes": [
+ {
+ "id": 2566,
+ "libraryName": {
+ "contractScope": null,
+ "id": 2564,
+ "name": "SafeMath",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 22354,
+ "src": "993:8:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_SafeMath_$22354",
+ "typeString": "library SafeMath"
+ }
+ },
+ "nodeType": "UsingForDirective",
+ "src": "987:27:3",
+ "typeName": {
+ "id": 2565,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1006:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ },
+ {
+ "canonicalName": "BancorX.Transaction",
+ "id": 2577,
+ "members": [
+ {
+ "constant": false,
+ "id": 2568,
+ "mutability": "mutable",
+ "name": "amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2577,
+ "src": "1142:14:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 2567,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1142:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 2570,
+ "mutability": "mutable",
+ "name": "fromBlockchain",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2577,
+ "src": "1167:22:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ "typeName": {
+ "id": 2569,
+ "name": "bytes32",
+ "nodeType": "ElementaryTypeName",
+ "src": "1167:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 2572,
+ "mutability": "mutable",
+ "name": "to",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2577,
+ "src": "1200:10:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 2571,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "1200:7:3",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 2574,
+ "mutability": "mutable",
+ "name": "numOfReports",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2577,
+ "src": "1221:18:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 2573,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "1221:5:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 2576,
+ "mutability": "mutable",
+ "name": "completed",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2577,
+ "src": "1250:14:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 2575,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "1250:4:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "name": "Transaction",
+ "nodeType": "StructDefinition",
+ "scope": 3447,
+ "src": "1112:160:3",
+ "visibility": "public"
+ },
+ {
+ "constant": true,
+ "functionSelector": "54fd4d50",
+ "id": 2580,
+ "mutability": "constant",
+ "name": "version",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 3447,
+ "src": "1280:34:3",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint16",
+ "typeString": "uint16"
+ },
+ "typeName": {
+ "id": 2578,
+ "name": "uint16",
+ "nodeType": "ElementaryTypeName",
+ "src": "1280:6:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint16",
+ "typeString": "uint16"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "34",
+ "id": 2579,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "number",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "1313:1:3",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_rational_4_by_1",
+ "typeString": "int_const 4"
+ },
+ "value": "4"
+ },
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "a8c36a90",
+ "id": 2582,
+ "mutability": "mutable",
+ "name": "maxLockLimit",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 3447,
+ "src": "1323:27:3",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 2581,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1323:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "52e94ce3",
+ "id": 2584,
+ "mutability": "mutable",
+ "name": "maxReleaseLimit",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 3447,
+ "src": "1438:30:3",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 2583,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1438:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "1fd8088d",
+ "id": 2586,
+ "mutability": "mutable",
+ "name": "minLimit",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 3447,
+ "src": "1555:23:3",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 2585,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1555:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "16c76c27",
+ "id": 2588,
+ "mutability": "mutable",
+ "name": "prevLockLimit",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 3447,
+ "src": "1675:28:3",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 2587,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1675:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "f7385f76",
+ "id": 2590,
+ "mutability": "mutable",
+ "name": "prevReleaseLimit",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 3447,
+ "src": "1767:31:3",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 2589,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1767:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "72f43d19",
+ "id": 2592,
+ "mutability": "mutable",
+ "name": "limitIncPerBlock",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 3447,
+ "src": "1862:31:3",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 2591,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1862:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "1aff29eb",
+ "id": 2594,
+ "mutability": "mutable",
+ "name": "prevLockBlockNumber",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 3447,
+ "src": "1949:34:3",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 2593,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "1949:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "4b3e475c",
+ "id": 2596,
+ "mutability": "mutable",
+ "name": "prevReleaseBlockNumber",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 3447,
+ "src": "2043:37:3",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 2595,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "2043:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "ca27e011",
+ "id": 2598,
+ "mutability": "mutable",
+ "name": "minRequiredReports",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 3447,
+ "src": "2140:31:3",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ },
+ "typeName": {
+ "id": 2597,
+ "name": "uint8",
+ "nodeType": "ElementaryTypeName",
+ "src": "2140:5:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "value": null,
+ "visibility": "public"
+ },
+ {
+ "baseFunctions": [
+ 3530
+ ],
+ "constant": false,
+ "functionSelector": "fc0c546a",
+ "id": 2601,
+ "mutability": "mutable",
+ "name": "token",
+ "nodeType": "VariableDeclaration",
+ "overrides": {
+ "id": 2600,
+ "nodeType": "OverrideSpecifier",
+ "overrides": [],
+ "src": "2262:8:3"
+ },
+ "scope": 3447,
+ "src": "2243:33:3",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ },
+ "typeName": {
+ "contractScope": null,
+ "id": 2599,
+ "name": "IERC20Token",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 21127,
+ "src": "2243:11:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "value": null,
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "fbb24692",
+ "id": 2604,
+ "mutability": "mutable",
+ "name": "xTransfersEnabled",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 3447,
+ "src": "2305:36:3",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 2602,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "2305:4:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "74727565",
+ "id": 2603,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "2337:4:3",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "true"
+ },
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "9390701c",
+ "id": 2607,
+ "mutability": "mutable",
+ "name": "reportingEnabled",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 3447,
+ "src": "2399:35:3",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "typeName": {
+ "id": 2605,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "2399:4:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "value": {
+ "argumentTypes": null,
+ "hexValue": "74727565",
+ "id": 2606,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "bool",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "2430:4:3",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "value": "true"
+ },
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "9ace38c2",
+ "id": 2611,
+ "mutability": "mutable",
+ "name": "transactions",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 3447,
+ "src": "2520:52:3",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_uint256_$_t_struct$_Transaction_$2577_storage_$",
+ "typeString": "mapping(uint256 => struct BancorX.Transaction)"
+ },
+ "typeName": {
+ "id": 2610,
+ "keyType": {
+ "id": 2608,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "2529:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Mapping",
+ "src": "2520:32:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_uint256_$_t_struct$_Transaction_$2577_storage_$",
+ "typeString": "mapping(uint256 => struct BancorX.Transaction)"
+ },
+ "valueType": {
+ "contractScope": null,
+ "id": 2609,
+ "name": "Transaction",
+ "nodeType": "UserDefinedTypeName",
+ "referencedDeclaration": 2577,
+ "src": "2540:11:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_struct$_Transaction_$2577_storage_ptr",
+ "typeString": "struct BancorX.Transaction"
+ }
+ }
+ },
+ "value": null,
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "e36f8dc5",
+ "id": 2615,
+ "mutability": "mutable",
+ "name": "transactionIds",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 3447,
+ "src": "2609:50:3",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_uint256_$_t_uint256_$",
+ "typeString": "mapping(uint256 => uint256)"
+ },
+ "typeName": {
+ "id": 2614,
+ "keyType": {
+ "id": 2612,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "2618:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Mapping",
+ "src": "2609:28:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_uint256_$_t_uint256_$",
+ "typeString": "mapping(uint256 => uint256)"
+ },
+ "valueType": {
+ "id": 2613,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "2629:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ },
+ "value": null,
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "8544c52d",
+ "id": 2621,
+ "mutability": "mutable",
+ "name": "reportedTxs",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 3447,
+ "src": "2735:65:3",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_uint256_$_t_mapping$_t_address_$_t_bool_$_$",
+ "typeString": "mapping(uint256 => mapping(address => bool))"
+ },
+ "typeName": {
+ "id": 2620,
+ "keyType": {
+ "id": 2616,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "2744:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Mapping",
+ "src": "2735:46:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_uint256_$_t_mapping$_t_address_$_t_bool_$_$",
+ "typeString": "mapping(uint256 => mapping(address => bool))"
+ },
+ "valueType": {
+ "id": 2619,
+ "keyType": {
+ "id": 2617,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "2764:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "nodeType": "Mapping",
+ "src": "2755:25:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
+ "typeString": "mapping(address => bool)"
+ },
+ "valueType": {
+ "id": 2618,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "2775:4:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ }
+ }
+ },
+ "value": null,
+ "visibility": "public"
+ },
+ {
+ "constant": false,
+ "functionSelector": "2cc1cd9e",
+ "id": 2625,
+ "mutability": "mutable",
+ "name": "reporters",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 3447,
+ "src": "2856:42:3",
+ "stateVariable": true,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
+ "typeString": "mapping(address => bool)"
+ },
+ "typeName": {
+ "id": 2624,
+ "keyType": {
+ "id": 2622,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "2865:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "nodeType": "Mapping",
+ "src": "2856:25:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_mapping$_t_address_$_t_bool_$",
+ "typeString": "mapping(address => bool)"
+ },
+ "valueType": {
+ "id": 2623,
+ "name": "bool",
+ "nodeType": "ElementaryTypeName",
+ "src": "2876:4:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ }
+ },
+ "value": null,
+ "visibility": "public"
+ },
+ {
+ "anonymous": false,
+ "documentation": {
+ "id": 2626,
+ "nodeType": "StructuredDocumentation",
+ "src": "2907:196:3",
+ "text": " @dev triggered when tokens are locked in smart contract\n @param _from wallet address that the tokens are locked from\n @param _amount amount locked"
+ },
+ "id": 2632,
+ "name": "TokensLock",
+ "nodeType": "EventDefinition",
+ "parameters": {
+ "id": 2631,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 2628,
+ "indexed": true,
+ "mutability": "mutable",
+ "name": "_from",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2632,
+ "src": "3136:21:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 2627,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "3136:7:3",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 2630,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2632,
+ "src": "3168:15:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 2629,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "3168:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "3125:65:3"
+ },
+ "src": "3109:82:3"
+ },
+ {
+ "anonymous": false,
+ "documentation": {
+ "id": 2633,
+ "nodeType": "StructuredDocumentation",
+ "src": "3199:204:3",
+ "text": " @dev triggered when tokens are released by the smart contract\n @param _to wallet address that the tokens are released to\n @param _amount amount released"
+ },
+ "id": 2639,
+ "name": "TokensRelease",
+ "nodeType": "EventDefinition",
+ "parameters": {
+ "id": 2638,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 2635,
+ "indexed": true,
+ "mutability": "mutable",
+ "name": "_to",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2639,
+ "src": "3439:19:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 2634,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "3439:7:3",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 2637,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2639,
+ "src": "3469:15:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 2636,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "3469:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "3428:63:3"
+ },
+ "src": "3409:83:3"
+ },
+ {
+ "anonymous": false,
+ "documentation": {
+ "id": 2640,
+ "nodeType": "StructuredDocumentation",
+ "src": "3500:352:3",
+ "text": " @dev triggered when xTransfer is successfully called\n @param _from wallet address that initiated the xtransfer\n @param _toBlockchain target blockchain\n @param _to target wallet\n @param _amount transfer amount\n @param _id xtransfer id"
+ },
+ "id": 2652,
+ "name": "XTransfer",
+ "nodeType": "EventDefinition",
+ "parameters": {
+ "id": 2651,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 2642,
+ "indexed": true,
+ "mutability": "mutable",
+ "name": "_from",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2652,
+ "src": "3884:21:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 2641,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "3884:7:3",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 2644,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_toBlockchain",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2652,
+ "src": "3916:21:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ "typeName": {
+ "id": 2643,
+ "name": "bytes32",
+ "nodeType": "ElementaryTypeName",
+ "src": "3916:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 2646,
+ "indexed": true,
+ "mutability": "mutable",
+ "name": "_to",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2652,
+ "src": "3948:19:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ "typeName": {
+ "id": 2645,
+ "name": "bytes32",
+ "nodeType": "ElementaryTypeName",
+ "src": "3948:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 2648,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2652,
+ "src": "3978:15:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 2647,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "3978:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 2650,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_id",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2652,
+ "src": "4004:11:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 2649,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "4004:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "3873:149:3"
+ },
+ "src": "3858:165:3"
+ },
+ {
+ "anonymous": false,
+ "documentation": {
+ "id": 2653,
+ "nodeType": "StructuredDocumentation",
+ "src": "4031:388:3",
+ "text": " @dev triggered when report is successfully submitted\n @param _reporter reporter wallet\n @param _fromBlockchain source blockchain\n @param _txId tx id on the source blockchain\n @param _to target wallet\n @param _amount transfer amount\n @param _xTransferId xtransfer id"
+ },
+ "id": 2667,
+ "name": "TxReport",
+ "nodeType": "EventDefinition",
+ "parameters": {
+ "id": 2666,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 2655,
+ "indexed": true,
+ "mutability": "mutable",
+ "name": "_reporter",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2667,
+ "src": "4450:25:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 2654,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "4450:7:3",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 2657,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_fromBlockchain",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2667,
+ "src": "4486:23:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ },
+ "typeName": {
+ "id": 2656,
+ "name": "bytes32",
+ "nodeType": "ElementaryTypeName",
+ "src": "4486:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bytes32",
+ "typeString": "bytes32"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 2659,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_txId",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2667,
+ "src": "4520:13:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 2658,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "4520:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 2661,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_to",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2667,
+ "src": "4544:11:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 2660,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "4544:7:3",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 2663,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_amount",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2667,
+ "src": "4566:15:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 2662,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "4566:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 2665,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_xTransferId",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2667,
+ "src": "4592:20:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 2664,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "4592:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "4439:180:3"
+ },
+ "src": "4425:195:3"
+ },
+ {
+ "anonymous": false,
+ "documentation": {
+ "id": 2668,
+ "nodeType": "StructuredDocumentation",
+ "src": "4628:157:3",
+ "text": " @dev triggered when final report is successfully submitted\n @param _to target wallet\n @param _id xtransfer id"
+ },
+ "id": 2674,
+ "name": "XTransferComplete",
+ "nodeType": "EventDefinition",
+ "parameters": {
+ "id": 2673,
+ "nodeType": "ParameterList",
+ "parameters": [
+ {
+ "constant": false,
+ "id": 2670,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_to",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2674,
+ "src": "4825:11:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ },
+ "typeName": {
+ "id": 2669,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "4825:7:3",
+ "stateMutability": "nonpayable",
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ },
+ {
+ "constant": false,
+ "id": 2672,
+ "indexed": false,
+ "mutability": "mutable",
+ "name": "_id",
+ "nodeType": "VariableDeclaration",
+ "overrides": null,
+ "scope": 2674,
+ "src": "4847:11:3",
+ "stateVariable": false,
+ "storageLocation": "default",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "typeName": {
+ "id": 2671,
+ "name": "uint256",
+ "nodeType": "ElementaryTypeName",
+ "src": "4847:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "value": null,
+ "visibility": "internal"
+ }
+ ],
+ "src": "4814:51:3"
+ },
+ "src": "4791:75:3"
+ },
+ {
+ "body": {
+ "id": 2775,
+ "nodeType": "Block",
+ "src": "6171:729:3",
+ "statements": [
+ {
+ "expression": {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ "id": 2729,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 2725,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 2723,
+ "name": "_minLimit",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2681,
+ "src": "6217:9:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 2724,
+ "name": "_maxLockLimit",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2677,
+ "src": "6230:13:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "6217:26:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "&&",
+ "rightExpression": {
+ "argumentTypes": null,
+ "commonType": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ },
+ "id": 2728,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftExpression": {
+ "argumentTypes": null,
+ "id": 2726,
+ "name": "_minLimit",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2681,
+ "src": "6247:9:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "BinaryOperation",
+ "operator": "<=",
+ "rightExpression": {
+ "argumentTypes": null,
+ "id": 2727,
+ "name": "_maxReleaseLimit",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2679,
+ "src": "6260:16:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "6247:29:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ "src": "6217:59:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ }
+ },
+ {
+ "argumentTypes": null,
+ "hexValue": "4552525f494e56414c49445f4d494e5f4c494d4954",
+ "id": 2730,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "kind": "string",
+ "lValueRequested": false,
+ "nodeType": "Literal",
+ "src": "6278:23:3",
+ "subdenomination": null,
+ "typeDescriptions": {
+ "typeIdentifier": "t_stringliteral_e8863683e853f5e973d186a95524b4cc24f1541517387abe8d8f6488ce1e0dc9",
+ "typeString": "literal_string \"ERR_INVALID_MIN_LIMIT\""
+ },
+ "value": "ERR_INVALID_MIN_LIMIT"
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_bool",
+ "typeString": "bool"
+ },
+ {
+ "typeIdentifier": "t_stringliteral_e8863683e853f5e973d186a95524b4cc24f1541517387abe8d8f6488ce1e0dc9",
+ "typeString": "literal_string \"ERR_INVALID_MIN_LIMIT\""
+ }
+ ],
+ "id": 2722,
+ "name": "require",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [
+ -18,
+ -18
+ ],
+ "referencedDeclaration": -18,
+ "src": "6209:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
+ "typeString": "function (bool,string memory) pure"
+ }
+ },
+ "id": 2731,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "functionCall",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6209:93:3",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_tuple$__$",
+ "typeString": "tuple()"
+ }
+ },
+ "id": 2732,
+ "nodeType": "ExpressionStatement",
+ "src": "6209:93:3"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 2735,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 2733,
+ "name": "maxLockLimit",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2582,
+ "src": "6391:12:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 2734,
+ "name": "_maxLockLimit",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2677,
+ "src": "6406:13:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "6391:28:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 2736,
+ "nodeType": "ExpressionStatement",
+ "src": "6391:28:3"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 2739,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 2737,
+ "name": "maxReleaseLimit",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2584,
+ "src": "6430:15:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 2738,
+ "name": "_maxReleaseLimit",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2679,
+ "src": "6448:16:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "6430:34:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 2740,
+ "nodeType": "ExpressionStatement",
+ "src": "6430:34:3"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 2743,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 2741,
+ "name": "minLimit",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2586,
+ "src": "6475:8:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 2742,
+ "name": "_minLimit",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2681,
+ "src": "6486:9:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "6475:20:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 2744,
+ "nodeType": "ExpressionStatement",
+ "src": "6475:20:3"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 2747,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 2745,
+ "name": "limitIncPerBlock",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2592,
+ "src": "6506:16:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 2746,
+ "name": "_limitIncPerBlock",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2683,
+ "src": "6525:17:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "6506:36:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 2748,
+ "nodeType": "ExpressionStatement",
+ "src": "6506:36:3"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 2751,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 2749,
+ "name": "minRequiredReports",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2598,
+ "src": "6553:18:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 2750,
+ "name": "_minRequiredReports",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2685,
+ "src": "6574:19:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "src": "6553:40:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ },
+ "id": 2752,
+ "nodeType": "ExpressionStatement",
+ "src": "6553:40:3"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 2755,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 2753,
+ "name": "prevLockLimit",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2588,
+ "src": "6697:13:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 2754,
+ "name": "_maxLockLimit",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2677,
+ "src": "6713:13:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "6697:29:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 2756,
+ "nodeType": "ExpressionStatement",
+ "src": "6697:29:3"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 2759,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 2757,
+ "name": "prevReleaseLimit",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2590,
+ "src": "6737:16:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 2758,
+ "name": "_maxReleaseLimit",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2679,
+ "src": "6756:16:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "6737:35:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 2760,
+ "nodeType": "ExpressionStatement",
+ "src": "6737:35:3"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 2764,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 2761,
+ "name": "prevLockBlockNumber",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2594,
+ "src": "6783:19:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 2762,
+ "name": "block",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -4,
+ "src": "6805:5:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_block",
+ "typeString": "block"
+ }
+ },
+ "id": 2763,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "number",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "6805:12:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "6783:34:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 2765,
+ "nodeType": "ExpressionStatement",
+ "src": "6783:34:3"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 2769,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 2766,
+ "name": "prevReleaseBlockNumber",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2596,
+ "src": "6828:22:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "expression": {
+ "argumentTypes": null,
+ "id": 2767,
+ "name": "block",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": -4,
+ "src": "6853:5:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_magic_block",
+ "typeString": "block"
+ }
+ },
+ "id": 2768,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "memberName": "number",
+ "nodeType": "MemberAccess",
+ "referencedDeclaration": null,
+ "src": "6853:12:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "src": "6828:37:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ },
+ "id": 2770,
+ "nodeType": "ExpressionStatement",
+ "src": "6828:37:3"
+ },
+ {
+ "expression": {
+ "argumentTypes": null,
+ "id": 2773,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "lValueRequested": false,
+ "leftHandSide": {
+ "argumentTypes": null,
+ "id": 2771,
+ "name": "token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2601,
+ "src": "6878:5:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "nodeType": "Assignment",
+ "operator": "=",
+ "rightHandSide": {
+ "argumentTypes": null,
+ "id": 2772,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2689,
+ "src": "6886:6:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "src": "6878:14:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ },
+ "id": 2774,
+ "nodeType": "ExpressionStatement",
+ "src": "6878:14:3"
+ }
+ ]
+ },
+ "documentation": {
+ "id": 2675,
+ "nodeType": "StructuredDocumentation",
+ "src": "4874:699:3",
+ "text": " @dev initializes a new BancorX instance\n @param _maxLockLimit maximum amount of tokens that can be locked in one transaction\n @param _maxReleaseLimit maximum amount of tokens that can be released in one transaction\n @param _minLimit minimum amount of tokens that can be transferred in one transaction\n @param _limitIncPerBlock how much the limit increases per block\n @param _minRequiredReports minimum number of reporters to report transaction before tokens can be released\n @param _registry address of contract registry\n @param _token erc20 token"
+ },
+ "id": 2776,
+ "implemented": true,
+ "kind": "constructor",
+ "modifiers": [
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 2692,
+ "name": "_registry",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2687,
+ "src": "5857:9:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IContractRegistry_$22831",
+ "typeString": "contract IContractRegistry"
+ }
+ }
+ ],
+ "id": 2693,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 2691,
+ "name": "ContractRegistryClient",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 21719,
+ "src": "5834:22:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_contract$_ContractRegistryClient_$21719_$",
+ "typeString": "type(contract ContractRegistryClient)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "5834:33:3"
+ },
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 2695,
+ "name": "_maxLockLimit",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2677,
+ "src": "5909:13:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 2696,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 2694,
+ "name": "greaterThanZero",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22595,
+ "src": "5893:15:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$_t_uint256_$",
+ "typeString": "modifier (uint256)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "5893:30:3"
+ },
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 2698,
+ "name": "_maxReleaseLimit",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2679,
+ "src": "5949:16:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 2699,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 2697,
+ "name": "greaterThanZero",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22595,
+ "src": "5933:15:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$_t_uint256_$",
+ "typeString": "modifier (uint256)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "5933:33:3"
+ },
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 2701,
+ "name": "_minLimit",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2681,
+ "src": "5992:9:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 2702,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 2700,
+ "name": "greaterThanZero",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22595,
+ "src": "5976:15:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$_t_uint256_$",
+ "typeString": "modifier (uint256)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "5976:26:3"
+ },
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 2704,
+ "name": "_limitIncPerBlock",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2683,
+ "src": "6028:17:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint256",
+ "typeString": "uint256"
+ }
+ }
+ ],
+ "id": 2705,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 2703,
+ "name": "greaterThanZero",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22595,
+ "src": "6012:15:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$_t_uint256_$",
+ "typeString": "modifier (uint256)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "6012:34:3"
+ },
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 2707,
+ "name": "_minRequiredReports",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2685,
+ "src": "6072:19:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_uint8",
+ "typeString": "uint8"
+ }
+ }
+ ],
+ "id": 2708,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 2706,
+ "name": "greaterThanZero",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22595,
+ "src": "6056:15:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$_t_uint256_$",
+ "typeString": "modifier (uint256)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "6056:36:3"
+ },
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 2712,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2689,
+ "src": "6123:6:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ }
+ ],
+ "expression": {
+ "argumentTypes": [
+ {
+ "typeIdentifier": "t_contract$_IERC20Token_$21127",
+ "typeString": "contract IERC20Token"
+ }
+ ],
+ "id": 2711,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": true,
+ "lValueRequested": false,
+ "nodeType": "ElementaryTypeNameExpression",
+ "src": "6115:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_type$_t_address_$",
+ "typeString": "type(address)"
+ },
+ "typeName": {
+ "id": 2710,
+ "name": "address",
+ "nodeType": "ElementaryTypeName",
+ "src": "6115:7:3",
+ "typeDescriptions": {
+ "typeIdentifier": null,
+ "typeString": null
+ }
+ }
+ },
+ "id": 2713,
+ "isConstant": false,
+ "isLValue": false,
+ "isPure": false,
+ "kind": "typeConversion",
+ "lValueRequested": false,
+ "names": [],
+ "nodeType": "FunctionCall",
+ "src": "6115:15:3",
+ "tryCall": false,
+ "typeDescriptions": {
+ "typeIdentifier": "t_address",
+ "typeString": "address"
+ }
+ }
+ ],
+ "id": 2714,
+ "modifierName": {
+ "argumentTypes": null,
+ "id": 2709,
+ "name": "validAddress",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 22618,
+ "src": "6102:12:3",
+ "typeDescriptions": {
+ "typeIdentifier": "t_modifier$_t_address_$",
+ "typeString": "modifier (address)"
+ }
+ },
+ "nodeType": "ModifierInvocation",
+ "src": "6102:29:3"
+ },
+ {
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "arguments": [
+ {
+ "argumentTypes": null,
+ "id": 2718,
+ "name": "_token",
+ "nodeType": "Identifier",
+ "overloadedDeclarations": [],
+ "referencedDeclaration": 2689,
+ "src": "6157:6:3",
+ "typeDescriptions": {
+