1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

compiler: scope type alias to module

This commit is contained in:
joe-conigliaro 2020-02-10 01:40:32 +11:00 committed by GitHub
parent 179fb13a17
commit 94537c5901
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 5 additions and 5 deletions

View File

@ -829,12 +829,12 @@ fn (p mut Parser) type_decl() {
p.fspace()
}
mut parent := Type{}
if !p.builtin_mod && p.mod != 'main' {
name = p.prepend_mod(name)
}
// Sum type
//is_sum := p.tok == .pipe
if is_sum {
if !p.builtin_mod && p.mod != 'main' {
name = p.prepend_mod(name)
}
// Register the first child (name we already parsed)
/*
p.table.register_type(Type{

View File

@ -11,7 +11,7 @@ pub const (
// Ref - https://docs.microsoft.com/en-us/windows/desktop/winprog/windows-data-types
// A handle to an object.
type HANDLE voidptr
pub type HANDLE voidptr
// win: FILETIME
// https://docs.microsoft.com/en-us/windows/win32/api/minwinbase/ns-minwinbase-filetime

View File

@ -17,7 +17,7 @@ struct C.CONSOLE_SCREEN_BUFFER_INFO {
dwMaximumWindowSize C.COORD
}
fn C.GetConsoleScreenBufferInfo(handle C.HANDLE, info &CONSOLE_SCREEN_BUFFER_INFO) bool
fn C.GetConsoleScreenBufferInfo(handle os.HANDLE, info &CONSOLE_SCREEN_BUFFER_INFO) bool
// get_terminal_size returns a number of colums and rows of terminal window.
pub fn get_terminal_size() (int, int) {