Ben Jones
c6286ab558
backend: use el_scancommas to skip over OPcomma chains
2024-05-02 01:52:26 +02:00
dokutoku
748fab1e02
Fix some invalid links ( #16424 )
...
Co-authored-by: dokutoku <3729541-dokutoku@users.noreply.gitlab.com>
2024-04-30 10:20:07 +03:00
Nick Treleaven
f1621176ef
Add tests for bug-prone EmptyStatements
...
Related: https://github.com/dlang/dmd/pull/15409 .
2024-04-30 01:23:13 +02:00
Dennis
b84fa4709f
Fix 22977 - can escape scope pointer returned by nested function ( #14236 )
2024-04-29 15:50:02 +03:00
Nick Treleaven
e60bfd11bd
Fix Bugzilla 24434 - Casting away const with cast() is not a @safe lv… ( #16315 )
...
* Fix Bugzilla 24434 - Casting away const with cast() is not a @safe lvalue
* Use `pointerTo`
* Use cast to hide lvalue append error
* Fix unsafe shared increment
* Use setUnsafePreview
* Add test for lvalue assign
* Fix qualifier cast check
* Workaround for safe append
Fixes Bugzilla 23530 - casting immutable away allowed in safe.
* Update header
* Trigger tests
2024-04-28 22:44:48 +08:00
Walter Bright
ca7ee01a53
builtins.d: use arrays instead of pointers
2024-04-28 07:07:08 +02:00
Walter Bright
4f21ff1fc5
escape.d: change Scope* to ref Scope
2024-04-28 07:06:56 +02:00
Dennis Korpel
c72c59a184
Remove unneeded @trusted
annotations
2024-04-27 14:56:27 +02:00
Nick Treleaven
32e4910ab3
Make foreach_reverse
with a delegate an error ( #16418 )
...
* Make `foreach_reverse` with a delegate an error
Deprecation goes back to at least 2016:
68fb91a130 (diff-13f50d9dea67df89a0535d6b8957f3145d49f71f6b72fdd3913f329a265e1423R1155)
2024-04-27 20:25:20 +08:00
Dennis Korpel
82f9402b6c
Mark some functions @safe
or @trusted
2024-04-27 00:43:22 +02:00
Dennis
9ffa763540
escape.d: Refactor EscapeByResults
more ( #16416 )
...
escape.d: Refactor `EscapeByResults` more
Signed-off-by: Nicholas Wilson <thewilsonator@users.noreply.github.com>
Merged-on-behalf-of: Dennis <dkorpel@users.noreply.github.com>
2024-04-26 13:15:04 +02:00
Dennis
e3ffb40283
escape.d: use callbacks for escapeByXXX instead of arrays ( #16412 )
...
* escape.d: use callbacks for escapeByXXX instead of arrays
* Fix null access
2024-04-26 12:55:50 +03:00
Iain Buclaw
5ce50ede24
Merge pull request #16409 from ibuclaw/merge_stable
...
merge stable
2024-04-26 07:09:00 +02:00
richard (rikki) andrew cattermole
011b2d3cd2
Fix lookup of ImportC character tables
2024-04-25 23:55:39 +02:00
Iain Buclaw
259e582f46
Merge remote-tracking branch 'upstream/stable' into merge_stable
2024-04-25 19:11:19 +00:00
Dennis Korpel
6c501f3e51
Fix Bugzilla 24519 - compiler segfault on default argument with slice operator []
2024-04-24 22:38:54 +08:00
Dennis
1da572ac2e
Fix bugzilla 23657 - [REG2.101] Incorrect error escape reference to stack allocated value ( #16407 )
...
Co-authored-by: Dennis Korpel <dennis@sarc.nl>
2024-04-24 14:35:43 +03:00
Dennis
49c4afd93f
Demangle symbols in linker errors ( #16021 )
...
* Demangle symbols in linker errors
Fix bugzilla issue 5573
* Fix test output regex of needspkgmod
---------
Co-authored-by: Dennis Korpel <dennis@sarc.nl>
2024-04-24 14:35:14 +03:00
Dennis Korpel
33c32407c0
Merge branch 'stable' into merge-stable
2024-04-23 14:44:01 +02:00
Dennis
499a85100a
Limit the number of deprecation messages by default ( #16403 )
2024-04-22 22:28:07 +08:00
Walter Bright
c09adbbc27
generalize isBorrowedPtr and isReadonlyPtr ( #16402 )
2024-04-20 23:22:19 -07:00
Ferhat Kurtulmuş
d61f72cbdc
Fix bugzilla 24509: importC cannot handle _stdcall Function Calling … ( #16392 )
...
* Fix bugzilla 24509: importC cannot handle _stdcall Function Calling Convention with single heading underscore
2024-04-21 11:30:22 +08:00
Harry Gillanders
978a26dd3d
Fix Bugzilla Issue 24511 - __stdcall functions from C are extern(C) in D.
2024-04-21 11:27:26 +08:00
Tim Schendekehl
f1307d6c75
Fix bugzilla 24498 - Multidimensional array not scanned by GC ( #16400 )
...
For expression `new int[][][](2, 2)` the relevant element type is
`int[]` and not `int`, because only two dimensions are allocated.
2024-04-19 22:13:27 +02:00
Nick Treleaven
56a0ea80b1
Fix Bugzilla 14128 - AliasDeclaration allows expressions, causing false … ( #15863 )
...
* Fix Issue 14128 - AliasDeclaration allows expressions, causing false code for ThisExp
* Add test case
* Fix deprecation comment
* Add changelog
* Use dummy out param, not null
* Change to error with __edition_latest_do_not_use
2024-04-19 17:55:31 +03:00
Martin Kinkelin
ec25e56a93
Fix bugzilla 24505 - ImportC: Don't generate symbols for #undef'd macros
2024-04-19 06:50:23 +08:00
Dennis
dc37b90ffe
dtoh: emit _d_dynamicArray only when needed ( #16397 )
2024-04-18 14:36:28 +02:00
Jonathan M Davis
ded14a2bb9
Fix bugzilla issue 24493: FreeBSD_14 version identifier missing ( #16368 )
...
Apparently, there were two problems that needed fixing.
1. The code for the FreeBSD_14 version identifier had not been added
yet.
2. The build did nothing to detect the version of FreeBSD, which makes
it very easy to build for the wrong version. The CI apparently sets
the version - e.g. TARGET_FREEBSD13 - but unless one of those
TARGET_FREEBSD* versions is set, the build defaults to FreeBSD 11,
which isn't even supported any longer.
So, this adds the code for the FreeBSD_14 identifier, and it makes it so
that the build queries the OS version on FreeBSD if TARGET_FREEBSD* has
not been set. So, anything that sets the TARGET_FREEBSD* version when
building will control the target version as before, but if it's not set,
then it will target whatever the current system is.
2024-04-18 14:40:20 +03:00
RazvanN7
9ca4c29549
Fix Bugzilla Issue 24479 - [REG2.104] Error on getAttributes on getOverloads of templates
2024-04-18 16:00:04 +08:00
Nick Treleaven
dca92a75b7
[editions] Make body
after contract an error ( #16382 )
...
* [editions] Make `body` after contract an error
* Mention --help in build.d module comment
* Add ASTBase.Module.edition property, always Edition.legacy for now
2024-04-18 10:26:20 +03:00
Dennis
3b3d496210
dtoh: export extern(Windows)
and extern(System)
functions ( #16394 )
...
Co-authored-by: Dennis Korpel <dennis@sarc.nl>
2024-04-18 10:09:52 +03:00
Walter Bright
75dca527f9
add DIP info to obj.d ( #16389 )
2024-04-16 21:27:54 +02:00
Walter Bright
9a86c4e06c
add find_files() to common/file.d ( #16365 )
2024-04-15 16:53:37 -07:00
Walter Bright
d434acd8ed
fix bugzilla Issue 21923 - @live does not take destructor code into account ( #16371 )
2024-04-15 14:46:23 -07:00
Walter Bright
274eec89f4
some conversion to foreach
2024-04-15 03:39:12 +02:00
Walter Bright
b8e9322fef
remove some 32 bit legacy
2024-04-14 18:00:10 +08:00
Walter Bright
77f640dcd0
use ref for el_copytotmp()
2024-04-14 12:23:29 +08:00
Walter Bright
1a5b706a92
use ref in el_parent()
2024-04-14 12:22:55 +08:00
Walter Bright
8275958d10
make el_const() @safe
2024-04-14 09:16:31 +08:00
Walter Bright
a858ef5d85
use ref in eltonear()
2024-04-14 09:15:51 +08:00
Walter Bright
4ceffb2a04
use out for el_ctor_dtor()
2024-04-14 01:17:46 +02:00
Walter Bright
22b8114e49
make el_same() parameter ref
2024-04-14 06:17:34 +08:00
Dennis Korpel
14137cecb5
Consolidate C struct initializer tests
2024-04-11 18:42:03 +08:00
Artha
4f69ba59f3
Fix bugzilla issue 24495 - ImportC: Struct initialization expression fails to initialize field
...
Makes it possible to use multiple designated initializers for anonymous
structs in expressions like `{{ .b = 2, .c = 3 }}`. This previously
worked only if there was one initializer.
2024-04-11 06:15:43 +08:00
Razvan Nitu
8f5c661c90
Fix Bugzilla 24485 - Invalid implicit ref return reinterpret cast for structs with copy constructor ( #16364 )
2024-04-10 15:44:40 +03:00
Walter Bright
a14af67ec4
fix bugzilla Issue 21854 - @live breaks foreach over integers
2024-04-09 14:38:55 +08:00
Walter Bright
06db0bf36e
trivial file edits
2024-04-09 13:14:53 +08:00
Bastiaan Veelo
d3db2e7cb3
Eliminate expressionsem import from attrib.d.
...
In pursuit of https://github.com/orgs/dlang/projects/41 .
2024-04-08 09:31:08 +08:00
Don Allen
6d87e8c197
Add -fPIC to DFLAGS. This is necessary to avoid issues with statics. ( #16362 )
...
modified: compiler/ini/freebsd/bin64/dmd.conf
2024-04-07 18:50:05 +02:00
Iain Buclaw
0cfdd7a589
Merge pull request #16340 from dkorpel/editions-experiment
...
Start implementation of editions
2024-04-05 12:19:38 +02:00