Diamond Rivero
7fa467eb40
Add initial playstation portable crossbuild
2025-01-11 08:28:06 +08:00
Yukihiro "Matz" Matsumoto
8276143f03
object.h: remove MRB_SET_FROZEN_FLAG/MRB_UNSET_FROZEN_FLAG macros
...
Simple `o->frozen = 1/0` now works.
2025-01-07 13:56:30 +09:00
Yukihiro "Matz" Matsumoto
c11d18e426
object.h: unify MRB_FROZEN_P() and mrb_frozen_p()
2025-01-07 11:24:58 +09:00
Yukihiro "Matz" Matsumoto
21003746df
object.h: separate frozen flag to the independent bit-field
...
So that other flag operation do not break frozen flag.
2025-01-07 07:44:10 +09:00
Yukihiro "Matz" Matsumoto
a234c66c97
class.c: removed a mistakenly copied function
2025-01-06 22:15:58 +09:00
Yukihiro "Matz" Matsumoto
003e0fb330
mruby-print: disable the gem unless explicitly specified
...
mruby-print is the duplicate of part of mruby-io. You need it only when
limited I/O functionality required.
2025-01-06 13:57:23 +09:00
Yukihiro "Matz" Matsumoto
ef88c3b726
kernel.c: move Kernel#p to kernel.c from mruby-print
...
It's easier to skip `p` in the debugger if it's implemented in C.
2025-01-06 13:57:23 +09:00
Yukihiro "Matz" Matsumoto
6f8bfed18e
object.h: change gccolor type to unsigned int
...
I was uncomfortable with the combination of an integer with a size
specification (uint32_t) and a bit field.
2025-01-06 13:56:58 +09:00
Yukihiro "Matz" Matsumoto
0e79f6b34b
include/object.h: rename color to gccolor
...
To clarify the color is for garbage collection.
2025-01-03 19:12:40 +09:00
Yukihiro "Matz" Matsumoto
4582cc8579
string.c: rename type setting macro
2025-01-03 09:29:43 +09:00
Yukihiro "Matz" Matsumoto
04ab2be2f0
mruby-string-ext (str_ascii_only_p): simplify the flag update
2025-01-03 08:47:38 +09:00
Yukihiro "Matz" Matsumoto
5a7c944a52
mruby-string-ext (str_b): simplify the flag update
2025-01-03 08:46:04 +09:00
Yukihiro "Matz" Matsumoto
8c2c57c59b
Merge pull request #6461 from dearblue/auto-release
2025-01-02 21:58:26 +09:00
Yukihiro "Matz" Matsumoto
e35c027966
Merge pull request #6463 from dearblue/dirname
2025-01-02 21:58:01 +09:00
Yukihiro "Matz" Matsumoto
1c50d1885d
Merge pull request #6462 from dearblue/mruby-io
2025-01-02 21:55:17 +09:00
Yukihiro "Matz" Matsumoto
b0127f0cdd
mruby-string-ext (str_b): add a new method String#b
...
The method makes the receiver binary-mode, but in mruby, which is
virtually no meaning.
2025-01-02 18:45:50 +09:00
dearblue
5c91014530
Add level argument to File.dirname
...
from Ruby-3.1
https://bugs.ruby-lang.org/issues/12194
2025-01-02 18:10:14 +09:00
dearblue
ef11cd94e7
Reimplement the File.dirname method
...
The purpose is as follows:
- Stop using `mrb_locale_from_utf8()`.
- Because there is no corresponding `mrb_utf8_from_locale()`.
- Because on Windows, for example, if the code page is 932 (CP932, likely ShiftJIS), it cannot be distinguished from the second byte 0x5c (\), and returns wrong results.
- Stop using `dirname(3)`.
- Because leading consecutive slashes are not truncated.
For example, if `/////a/b` is given, CRuby returns `/a`, but mruby so far returns `/////a`.
- Because the `path` argument cannot be passed in an immutable form.
- Stop using `_splitpath()` in the Windows implementation.
- Because there is no support for UNC paths with up to 32767 characters.
ref. https://learn.microsoft.com/ja-jp/dotnet/standard/io/file-path-formats#unc-paths
- Because modifying the result of paths terminated by a directory separator.
Previously, for example, `C:/` would return `C:.` instead of `C:/`, and `a/b/` would return `a/b` instead of `a`.
2025-01-02 17:42:40 +09:00
dearblue
3b659f5320
Properly cast the return value of memchr()
2025-01-02 15:34:36 +09:00
dearblue
af1e33c442
To create a release package file in draft
...
This is to allow final confirmation of the created release file.
Release files in draft form cannot be downloaded by the general public.
2025-01-01 20:24:56 +09:00
Yukihiro "Matz" Matsumoto
85df487e63
mruby-string-ext (append_as_bytes): new method introduced by CRuby 3.4
...
Since mruby does not have Encoding support, append_as_bytes works
exactly same as String#concat.
2025-01-01 16:05:00 +09:00
Yukihiro "Matz" Matsumoto
9f59d26c35
class.c: adjust space around the operator
2024-12-30 22:45:13 +09:00
Yukihiro "Matz" Matsumoto
59d1fcfa02
include/proc/h: add 2 new constants for the future
2024-12-29 18:04:40 +09:00
Yukihiro "Matz" Matsumoto
d7559253de
mruby-compiler: need to add proper type cast for C++
2024-12-28 11:39:22 +09:00
Yukihiro "Matz" Matsumoto
86a40189b4
class.c: remove _P suffix from non predicate
2024-12-28 11:18:46 +09:00
Yukihiro "Matz" Matsumoto
0b5ebf1b79
class.c: avoid using separate values in files
2024-12-27 18:49:35 +09:00
Yukihiro "Matz" Matsumoto
cf8e0f3f47
class.c: define MT_KEY_SHIFT (2) for the future
2024-12-27 18:39:46 +09:00
Yukihiro "Matz" Matsumoto
32d11d86ff
mruby-compiler (new_lit_str2): move declarations to the point needed
2024-12-26 09:58:01 +09:00
Yukihiro "Matz" Matsumoto
648495a4b3
mruby-compiler (mrb_prev_pc): remove unnecessary local variable
2024-12-25 12:40:33 +09:00
Yukihiro "Matz" Matsumoto
160935dc24
mruby-compiler (mrb_prev_pc): add assertion to ensure pc within iseq
2024-12-25 12:39:57 +09:00
Yukihiro "Matz" Matsumoto
dbcb5b5a6d
mruby-compiler (merge_pool_str): check whether merged string is in the pool
2024-12-25 12:39:34 +09:00
Yukihiro "Matz" Matsumoto
890a8362b6
mruby-compiler (new_lit_str2): fixed a bug in pool string equality check
2024-12-25 12:39:34 +09:00
Yukihiro "Matz" Matsumoto
6687bddba3
mruby-compiler (gen_addsub): merge 2 literal strings str + str
...
Unlike previous attempt, this change can merge sequence of plus
operations (e.g. `str + str + str`). Need more tests though.
2024-12-25 12:39:34 +09:00
Yukihiro "Matz" Matsumoto
b44372599e
mruby-compiler (codegen): combine literal str + str to one string
2024-12-25 12:39:34 +09:00
Yukihiro "Matz" Matsumoto
61f57b22dd
Merge pull request #6459 from dearblue/FileTest
2024-12-25 00:04:11 +09:00
dearblue
7c69a37aa6
FileTest is a module
...
It has been incorrectly defined as a class.
2024-12-23 22:45:47 +09:00
Yukihiro "Matz" Matsumoto
6037e50298
test/hash: update tests to new hash format
2024-12-21 08:53:57 +09:00
Yukihiro "Matz" Matsumoto
baeeb5e435
hash.c (mrb_hash_to_s): print :sym => val as sym: val
...
Ruby 3.4 changed the format of hash string representation. We follow.
2024-12-21 08:52:23 +09:00
Yukihiro "Matz" Matsumoto
e31869fd91
mruby-fiber: rename fiber_init_fiber to init_fiber
...
Resolve confusing function names
2024-12-20 17:56:25 +09:00
Yukihiro "Matz" Matsumoto
583aa985c8
mruby-compiler (gen_call): use OP_SSEND for self.foo() calls
2024-12-20 10:05:09 +09:00
Yukihiro "Matz" Matsumoto
aad7dce017
gc.c (mark_context_stack): use SET_NIL_VALUE macro to clear the stack
2024-12-19 16:20:46 +09:00
Yukihiro "Matz" Matsumoto
c83bddd856
mruby-bigint (bint_new): avoid memcpy'ing NULL pointer
...
The second argument of memcpy() is declared to never be NULL. Clang ASAN
report this as an undefined behavior error.
2024-12-18 13:48:11 +09:00
Yukihiro "Matz" Matsumoto
18cc2cea41
mruby-compiler (codegen): loop info may be NULL (retry)
2024-12-17 10:41:23 +09:00
Yukihiro "Matz" Matsumoto
a77b9b4bab
mruby-compiler (codegen): loop info may be NULL (redo)
2024-12-17 10:41:23 +09:00
Yukihiro "Matz" Matsumoto
f67939ff78
Merge pull request #6458 from mruby/dependabot/github_actions/super-linter/super-linter-7.2.1
2024-12-17 10:32:32 +09:00
dependabot[bot]
8099db94ff
Bump super-linter/super-linter from 7.2.0 to 7.2.1
...
Bumps [super-linter/super-linter](https://github.com/super-linter/super-linter ) from 7.2.0 to 7.2.1.
- [Release notes](https://github.com/super-linter/super-linter/releases )
- [Changelog](https://github.com/super-linter/super-linter/blob/main/CHANGELOG.md )
- [Commits](https://github.com/super-linter/super-linter/compare/v7.2.0...v7.2.1 )
---
updated-dependencies:
- dependency-name: super-linter/super-linter
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-12-16 14:23:58 +00:00
Yukihiro "Matz" Matsumoto
2f5c2d6b42
Revert "vm.c (OP_ENTER): clear all registers region in the stack"
...
This reverts commit 19385a8710 .
The issue is covered by 1003a6.
2024-12-16 19:26:56 +09:00
Yukihiro "Matz" Matsumoto
d1003a6f9a
mruby-fiber (fiber_init_fiber): clear all of fiber stack allocated
2024-12-16 19:23:05 +09:00
Yukihiro "Matz" Matsumoto
19385a8710
vm.c (OP_ENTER): clear all registers region in the stack
...
To keep GC away from touching uninitialized values
2024-12-15 23:23:07 +09:00
Yukihiro "Matz" Matsumoto
d13e6ff8c9
include/presym.h: MRB_GVSYM() for global variables is now available
2024-12-14 16:03:35 +09:00