mirror of
https://github.com/vlang/v.git
synced 2025-09-09 07:15:50 -04:00
checker: bring back pascal case check for aliases
This commit is contained in:
parent
82a3e67d3f
commit
6f79eecce0
@ -227,7 +227,7 @@ fn C.sysctl(name &int, namelen u32, oldp voidptr, oldlenp voidptr, newp voidptr,
|
||||
[trusted]
|
||||
fn C._fileno(int) int
|
||||
|
||||
struct C.intptr_t {}
|
||||
type C.intptr_t = voidptr
|
||||
|
||||
fn C._get_osfhandle(fd int) C.intptr_t
|
||||
|
||||
|
@ -499,10 +499,9 @@ fn (mut c Checker) type_decl(node ast.TypeDecl) {
|
||||
}
|
||||
|
||||
fn (mut c Checker) alias_type_decl(node ast.AliasTypeDecl) {
|
||||
// TODO Remove when `u8` isn't an alias in builtin anymore
|
||||
// if c.file.mod.name != 'builtin' {
|
||||
// c.check_valid_pascal_case(node.name, 'type alias', node.pos)
|
||||
//}
|
||||
if c.file.mod.name != 'builtin' && c.file.mod.name != 'time' {
|
||||
c.check_valid_pascal_case(node.name, 'type alias', node.pos)
|
||||
}
|
||||
if !c.ensure_type_exists(node.parent_type, node.type_pos) {
|
||||
return
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user