Bump dmd version
This commit is contained in:
parent
c7df69a7a7
commit
96b1f61ec2
2
dmd
2
dmd
|
|
@ -1 +1 @@
|
||||||
Subproject commit a4cbc08f5bc1a2f7ce3289103198c473671e94c0
|
Subproject commit 2d5cd3166b6cce7404c812a8f04156dc2f1108b5
|
||||||
2
dub.json
2
dub.json
|
|
@ -18,7 +18,7 @@
|
||||||
"libddoc": "~>0.8.0",
|
"libddoc": "~>0.8.0",
|
||||||
"dmd": {
|
"dmd": {
|
||||||
"repository": "git+https://github.com/dlang/dmd.git",
|
"repository": "git+https://github.com/dlang/dmd.git",
|
||||||
"version": "a4cbc08f5bc1a2f7ce3289103198c473671e94c0"
|
"version": "2d5cd3166b6cce7404c812a8f04156dc2f1108b5"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"targetPath" : "bin",
|
"targetPath" : "bin",
|
||||||
|
|
|
||||||
39
makefile
39
makefile
|
|
@ -9,36 +9,19 @@ GDC := gdc
|
||||||
LDC := ldc2
|
LDC := ldc2
|
||||||
|
|
||||||
DMD_FRONTEND_SRC := \
|
DMD_FRONTEND_SRC := \
|
||||||
$(shell find dmd/compiler/src/dmd/common -name "*.d")\
|
$(shell find dmd/compiler/src/dmd -maxdepth 2 -name "*.d" \
|
||||||
$(shell find dmd/compiler/src/dmd/root -name "*.d")\
|
|
||||||
$(shell find dmd/compiler/src/dmd/visitor -name "*.d")\
|
|
||||||
$(shell find dmd/compiler/src/dmd/mangle -name "*.d")\
|
|
||||||
$(shell find dmd/compiler/src/dmd -maxdepth 1 -name "*.d" \
|
|
||||||
! -name "mars.d" \
|
! -name "mars.d" \
|
||||||
! -name "dmsc.d" \
|
! -name "dmsc.d" \
|
||||||
! -name "e2ir.d" \
|
! -name "*elf*.d" \
|
||||||
! -name "eh.d" \
|
! -name "*mscoff*.d" \
|
||||||
! -name "glue.d" \
|
! -name "*mach*.d" \
|
||||||
! -name "iasmdmd.d" \
|
! -name "*dwarfdbginf*.d" \
|
||||||
! -name "irstate.d" \
|
! -path "*/glue/*" \
|
||||||
! -name "lib.d" \
|
! -path "*/lib/*" \
|
||||||
! -name "libelf.d" \
|
! -path "*/backend/*" \
|
||||||
! -name "libmach.d" \
|
! -path "*/iasm/dmd*" \
|
||||||
! -name "libmscoff.d" \
|
) \
|
||||||
! -name "libomf.d" \
|
|
||||||
! -name "objc_glue.d" \
|
|
||||||
! -name "s2ir.d" \
|
|
||||||
! -name "scanelf.d" \
|
|
||||||
! -name "scanmach.d" \
|
|
||||||
! -name "scanmscoff.d" \
|
|
||||||
! -name "scanomf.d" \
|
|
||||||
! -name "tocsym.d" \
|
|
||||||
! -name "toctype.d" \
|
|
||||||
! -name "tocvdebug.d" \
|
|
||||||
! -name "toobj.d" \
|
|
||||||
! -name "todt.d" \
|
|
||||||
! -name "toir.d" \
|
|
||||||
)
|
|
||||||
|
|
||||||
LIB_SRC := \
|
LIB_SRC := \
|
||||||
$(shell find containers/src -name "*.d")\
|
$(shell find containers/src -name "*.d")\
|
||||||
|
|
|
||||||
|
|
@ -35,7 +35,7 @@ extern (C++) class LengthSubtractionCheck(AST) : BaseAnalyzerDmd
|
||||||
if (left.ident.toString() == "length")
|
if (left.ident.toString() == "length")
|
||||||
addErrorMessage(
|
addErrorMessage(
|
||||||
cast(ulong) left.loc.linnum, cast(ulong) left.loc.charnum, KEY, MSG,
|
cast(ulong) left.loc.linnum, cast(ulong) left.loc.charnum, KEY, MSG,
|
||||||
[AutoFix.insertionAt(minExpr.loc.fileOffset, "cast(ptrdiff_t) ")]
|
[AutoFix.insertionAt(left.e1.loc.fileOffset, "cast(ptrdiff_t) ")]
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ module dscanner.analysis.mismatched_args;
|
||||||
|
|
||||||
import dscanner.analysis.base;
|
import dscanner.analysis.base;
|
||||||
import std.format : format;
|
import std.format : format;
|
||||||
import dmd.arraytypes : Identifiers;
|
import dmd.arraytypes : ArgumentLabels;
|
||||||
|
|
||||||
/// Checks for mismatched argument and parameter names
|
/// Checks for mismatched argument and parameter names
|
||||||
extern (C++) class MismatchedArgumentCheck(AST) : BaseAnalyzerDmd
|
extern (C++) class MismatchedArgumentCheck(AST) : BaseAnalyzerDmd
|
||||||
|
|
@ -87,17 +87,18 @@ extern (C++) class MismatchedArgumentCheck(AST) : BaseAnalyzerDmd
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private extern (D) bool[int] getNamedArgsPositions(Identifiers* names, string funcName)
|
private extern (D) bool[int] getNamedArgsPositions(ArgumentLabels* labels, string funcName)
|
||||||
{
|
{
|
||||||
bool[int] namedArgsPositions;
|
bool[int] namedArgsPositions;
|
||||||
|
|
||||||
if (names is null || (funcName in funcsWithParams) is null)
|
if (labels is null || (funcName in funcsWithParams) is null)
|
||||||
return namedArgsPositions;
|
return namedArgsPositions;
|
||||||
|
|
||||||
auto funcParams = funcsWithParams[funcName];
|
auto funcParams = funcsWithParams[funcName];
|
||||||
|
|
||||||
foreach (name; *names)
|
foreach (label; *labels)
|
||||||
{
|
{
|
||||||
|
const name = label.name;
|
||||||
if (name is null)
|
if (name is null)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue