Skip to content

Commit

Permalink
checker: remove time_t hack now that C aliases are supported
Browse files Browse the repository at this point in the history
  • Loading branch information
medvednikov committed Oct 14, 2023
1 parent 545ee1a commit 8f76a06
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion vlib/time/time.c.v
Expand Up @@ -16,7 +16,7 @@ fn C.localtime_r(t &C.time_t, tm &C.tm)

// struct C.time_t {}

// type C.time_t = i64
type C.time_t = i64

fn C.time(t &C.time_t) C.time_t

Expand Down
8 changes: 4 additions & 4 deletions vlib/v/checker/checker.v
Expand Up @@ -4700,10 +4700,10 @@ fn (mut c Checker) ensure_type_exists(typ ast.Type, pos token.Pos) bool {
}
match sym.kind {
.placeholder {
if sym.language == .c && sym.name == 'C.time_t' {
// TODO temporary hack until we can define C aliases
return true
}
// if sym.language == .c && sym.name == 'C.time_t' {
// TODO temporary hack until we can define C aliases
// return true
//}
// if sym.language == .v && !sym.name.starts_with('C.') {
// if sym.language in [.v, .c] {
if sym.language == .v {
Expand Down

0 comments on commit 8f76a06

Please sign in to comment.