Commit Graph

23 Commits

Author SHA1 Message Date
Andreas Rumpf
6c1c8f51b3 IC: green tests (#17311)
* IC: renamed to_packed_ast module to ic module

* IC: don't store the --forceBuild flag, makes it easier to test

* IC: enable hello world test

* Codegen: refactorings for IC; changed the name mangling algorithm

* fixed the HCR regressions

* life is too short for HCR

* tconvexhull is now allowed to use deepCopy

* IC exposed a stdlib bug, required a refactoring

* codegen: code cleanups

* IC: even if a module is outdated, its dependencies might come from disk

* IC: progress

* IC: better name mangling, module IDs are not stable

* IC: another refactoring helping with --ic:on --gc:arc

* disable arraymancer on Windows for the time being

* disable arraymancer altogether

* IC: make basic test work with 'nim cpp'

* IC: progress on --ic:on --gc:arc

* wip; name mangling for type info
2021-03-19 16:53:38 +01:00
Timothee Cour
b9994925f5 remove all uses of condsyms symbols defined prior to bootstrap nim 0.20.0 (#16918)
* nimNoArrayToCstringConversion deadcode
* nimbabel deadcode
* nimHasalignOf deadcode
* nimvarargstyped deadcode
* nimhygiene deadcode
* nimNewTypedesc deadcode
* nimlocks deadcode
* nimHasCppDefine deadcode
* nimHasRunnableExamples deadcode
* nimHasNilChecks deadcode
* nimSymKind deadcode
* minor macros refactoring
* nimVmEqIdent deadcode
* nimNoNil deadcode
* nimNoZeroTerminator deadcode
* nimHasSymOwnerInMacro deadcode
* nimVmExportFixed deadcode
* nimNewRuntime deadcode
* nimAshr deadcode
* nimUncheckedArrayTyp deadcode
* nimHasTypeof deadcode
* nimErrorProcCanHaveBody deadcode
* nimHasHotCodeReloading deadcode
* nimHasSignatureHashInMacro deadcode
* nimHasDefault deadcode
* nimMacrosSizealignof deadcode
2021-02-17 09:32:36 +01:00
konsumlamm
0a9a90d991 Improve documentation for bitops (#16961)
* Improve documentation for bitops

Use func
Use let in runnableExamples

* Remove unnecessary tests

Fix #7587
2021-02-15 21:17:45 +01:00
rockcavera
4576cf20af Refactoring bitops.rotateLeftBits() and bitops.rotateRightBits(); adding builtins and intrinsics. (#16622)
Co-authored-by: Timothee Cour <timothee.cour2@gmail.com>
2021-02-08 16:36:41 -08:00
rockcavera
876fa3e62e adding missing commas in std/bitops (#16520)
adding missing commas between the importc and header pragmas of some procs.
2020-12-30 16:41:25 -08:00
Andreas Rumpf
da29222f86 init checks and 'out' parameters (#14521)
* I don't care about observable stores
* enforce explicit initializations
* cleaner code for the stdlib
* stdlib: use explicit initializations
* make tests green
* algorithm.nim: set result explicitly
* remove out parameters and bring the PR into a mergable state
* updated the changelog
2020-06-23 10:53:57 +02:00
awr1
b70b8a7cdd Fix runnable examples for bitops (#14247) 2020-05-06 19:29:36 +02:00
awr1
b8e6ea7547 Added bitslice operations for bitops (#14016)
* added bit operations based on bit slices, clarified documentation, made non-mutating versions of mask ops
* Added since annotations, some runnable examples
* Added mask()/masked() functions, changed internal workings of mask ops to use new bit* funcs
* Changelog updated for new bitops improvements
* Reorganization, added runnable examples
* Documentation adjustments
* Add incltrl for since annotation
* Fix masked() impl
* Fix mask() return type
* Don't call toUnsigned on already unsigned types
* Remove improper `var T` for flipMasked()
* Fix return types for flipMasked()
* Slight syntactic cleanup for *masked ops
* Added tests for bitslice operations, new mask() operation, non-mutating mask ops
* Fix setmasked() var T issue
* More comprehensive tests
* Fix runnable example for bitsliced()
* Fix runnable example for mask()
2020-05-06 12:21:49 +02:00
awr1
59aeaa1c98 Make bitand, bitor, bitxor varargs-friendly (#13985)
* made bitand, bitor, bitxor varargs friendly
* changed new bitops to macros
* changed macro signature for consistency (this technically doesn't matter)
* added tests
* removed redundant assert
* fix literal
2020-04-20 14:48:37 +02:00
jiro
40b64ccd7b Add runnableExamples to bitops module (#13951)
* doc: bitops: add runnableExamples

* doc: bitops: add notes to documentation comments of macros

* doc: bitops: add periods to documentation comments

* doc: bitops: add static

* Revert "doc: bitops: add static"

This reverts commit 595ee134ab.

* doc: bitops: add `var` to arguments of macros

* doc: bitops: remove examples of testBit
2020-04-13 14:21:45 +02:00
Nindaleth
34dbc5699e fix several typos in documentation and comments (#12553) 2019-10-30 09:08:45 +01:00
narimiran
34d0be2ec1 [backport] run nimpretty on os-related stuff 2019-09-30 13:58:15 +02:00
Federico Ceratto
39290cf88c Fix spellings (#12277) [backport] 2019-09-27 07:02:54 +02:00
Araq
c94647aeca styleCheck: make the compiler and large parts of the stdlib compatible with --styleCheck:error 2019-07-10 12:42:41 +02:00
Arne Döring
cfeb9d2c50 Bit operator names 2 (#11413)
* add bit operator names

* add test for bitop alias
2019-06-06 08:36:20 +02:00
Oscar Nihlgård
3a06022071 Enable range checking for unsigned integers (#11313)
* Enable range checking for unsigned integers

* Make the tests green
2019-05-25 20:48:13 +02:00
Arne Döring
e904b3f952 code cleanup (#10874) 2019-03-28 12:32:02 +01:00
Tomohiro
cd3a58d7b0 bitops: add reverseBits and test (#10835) 2019-03-13 15:53:40 +01:00
silent-observer
7e52c798db Remove var
Shouldn't testing bit require only immutable access? I think this is a typo
2019-03-05 14:19:41 +05:00
Arne Döring
824f39b32e Vm bitops fixes (#10520) 2019-02-05 09:31:37 +01:00
Ico Doornekamp
0d480bfe22 Added basic bit manipulation procs to bitops (#10338) 2019-01-23 09:16:14 +01:00
Araq
9820c2c456 bitops: add 'hamming weight' to the doc index 2017-12-03 15:20:50 +01:00
Parashurama
976095c894 add bitops module for optimized bit manipulation. (#5201) 2017-03-14 21:32:54 +01:00