aboutsummaryrefslogtreecommitdiffstats
path: root/internal
Commit message (Collapse)AuthorAgeFilesLines
...
* internal/variable.h rework卜部昌平2019-12-261-15/+48
| | | | | Eliminated macros. Also marked MJIT_FUNC_EXPORTED functions as such. Some of them are declared in constant.h so edited that file also.
* internal/imemo.h rework卜部昌平2019-12-261-97/+122
| | | | | | Arrange contents and eliminate macros, to make them readable. Macro IFUNC_NEW was deleted because there was only one usage.
* internal/class.h rework卜部昌平2019-12-261-34/+46
| | | | | | | | This file has almost nothing to do. Added some #ifdef lines and rearranged file contents. Those macros are unable to translate into inline functions, because they are used as lvalues of assignments.
* internal/struct.h rework卜部昌平2019-12-261-32/+82
| | | | | Replace macros with inline functions of equivalent contents, for much improved readability.
* internal/hash.h rework卜部昌平2019-12-261-79/+164
| | | | | | | | Reduce macros to make them inline functions, as well as mark MJIT_FUNC_EXPORTED functions explicitly as such. Definition of ar_hint_t is simplified. This has been the only possible definition so far.
* internal/numeric.h rework卜部昌平2019-12-261-34/+61
| | | | | Marked MJIT_FUNC_EXPORTED functions as such. Other changes are rather cosmetic.
* internal/bingnum.h rework卜部昌平2019-12-261-35/+106
| | | | | Turn macros into inline functions for better readability. Also add rb_int128t2big delcaration, which was missing.
* internal/fixnum.h rework卜部昌平2019-12-263-14/+56
| | | | Add #include lines, move FIXNUM_POSITIVE_P etc. from numeric.h.
* internal/static_assert.h rework卜部昌平2019-12-261-6/+13
| | | | | ISO/IEC 9899:2011 section 7.2 states that <assert.h> must define static_assert. Use it when available.
* internal/warnings.h rework卜部昌平2019-12-261-30/+29
| | | | Not a big rewrite. Just to make those macros readable.
* internal/bits.h rework卜部昌平2019-12-262-186/+439
| | | | | | Improving readability by converting some macros into inline functions. Also improved support for recent x86_64 processors, which have better instructions for the purposes.
* add several __has_something macro卜部昌平2019-12-262-7/+94
| | | | | | | With these macros implemented we can write codes just like we can assume the compiler being clang. MSC_VERSION_SINCE is defined to implement those macros, but turned out to be handy for other places. The -fdeclspec compiler flag is necessary for clang to properly handle __has_declspec().
* assume C99卜部昌平2019-12-261-15/+7
| | | | | | | | | | | Now that we no longer support old compilers, we can safely delete several obsolete #ifdef gurads. Also because (as of writing) it is impossible to compile the program using C++ compilers, lets just entirely prohibit __cplusplus to reduce # of LOCs. Note however that we still cannot eliminate __STDC_VERSION__ checks, because MSVC does not define it, saying its C99 support is partial. See also https://social.msdn.microsoft.com/Forums/vstudio/en-US/53a4fd75-9f97-48b2-aa63-2e2e5a15efa3
* split internal.h into files卜部昌平2019-12-2653-0/+3390
One day, I could not resist the way it was written. I finally started to make the code clean. This changeset is the beginning of a series of housekeeping commits. It is a simple refactoring; split internal.h into files, so that we can divide and concur in the upcoming commits. No lines of codes are either added or removed, except the obvious file headers/footers. The generated binary is identical to the one before.