diff options
| author | DanielGavin <danielgavin5@hotmail.com> | 2021-03-12 16:38:54 +0100 |
|---|---|---|
| committer | DanielGavin <danielgavin5@hotmail.com> | 2021-03-12 16:38:54 +0100 |
| commit | 9b01ac03a7efe6a6589c49a4ce02dff3f723c38a (patch) | |
| tree | 4c716902376f950d338c3e13c2f26c004a0083fd /src | |
| parent | 00ccd7e03e17dac40efb9b34a048d968dd77c218 (diff) | |
ran odinfmt again(it didn't newline at th eof)
Diffstat (limited to 'src')
38 files changed, 43 insertions, 39 deletions
diff --git a/src/common/allocator.odin b/src/common/allocator.odin index 0adbedf..a7bfae7 100644 --- a/src/common/allocator.odin +++ b/src/common/allocator.odin @@ -118,4 +118,4 @@ scratch_allocator :: proc (allocator: ^Scratch_Allocator) -> mem.Allocator { procedure = scratch_allocator_proc, data = allocator, }; -}
\ No newline at end of file +} diff --git a/src/common/ast.odin b/src/common/ast.odin index 98f2d84..c807ce8 100644 --- a/src/common/ast.odin +++ b/src/common/ast.odin @@ -611,4 +611,4 @@ node_equal_node :: proc (a, b: ^ast.Node) -> bool { } return false; -}
\ No newline at end of file +} diff --git a/src/common/config.odin b/src/common/config.odin index ddf4d2a..df6ddb1 100644 --- a/src/common/config.odin +++ b/src/common/config.odin @@ -10,4 +10,4 @@ Config :: struct { verbose: bool, debug_single_thread: bool, enable_semantic_tokens: bool, //This will be removed when vscode client stops sending me semantic tokens after disabling it in requests initialize. -}
\ No newline at end of file +} diff --git a/src/common/fuzzy.odin b/src/common/fuzzy.odin index f0b4a82..51c43ff 100644 --- a/src/common/fuzzy.odin +++ b/src/common/fuzzy.odin @@ -27,6 +27,7 @@ FuzzyCharRole :: enum (u8) // Stray control characters or impossible states. // Part of a word segment, but not the first character. // The first character of a word segment. + { Unknown = 0, Tail = 1, @@ -38,6 +39,7 @@ FuzzyCharType :: enum (u8) // Before-the-start and after-the-end (and control chars). // Lowercase letters, digits, and non-ASCII bytes. // Uppercase letters. + { Empty = 0, Lower = 1, @@ -63,7 +65,9 @@ FuzzyMatcher :: struct { char_roles: []u8 = // clang-format off // Curr= Empty Lower Upper Separ -/*Prev=Empty */{ +/*Prev=Empty */ + +{ 0x00,0xaa,0xaa,0xff, // At start, Lower|Upper->Head /*Prev=Lower */0x00,0x55,0xaa,0xff, // In word, Upper->Head;Lower->Tail /*Prev=Upper */0x00,0x55,0x59,0xff, // Ditto, but U(U)U->Tail @@ -413,4 +417,4 @@ fuzzy_allow_match :: proc (matcher: ^FuzzyMatcher, p: int, w: int, last: int) -> } return true; -}
\ No newline at end of file +} diff --git a/src/common/pool.odin b/src/common/pool.odin index 6789b63..422b8f7 100644 --- a/src/common/pool.odin +++ b/src/common/pool.odin @@ -153,4 +153,4 @@ pool_wait_and_process :: proc (pool: ^Pool) { } pool_join(pool); -}
\ No newline at end of file +} diff --git a/src/common/position.odin b/src/common/position.odin index 9145091..c409b2f 100644 --- a/src/common/position.odin +++ b/src/common/position.odin @@ -271,4 +271,4 @@ get_end_line_u16 :: proc (document_text: []u8) -> int { } return utf16_idx; -}
\ No newline at end of file +} diff --git a/src/common/pretty.odin b/src/common/pretty.odin index ff0d5ff..929bf80 100644 --- a/src/common/pretty.odin +++ b/src/common/pretty.odin @@ -237,4 +237,4 @@ print_ast_node :: proc (node: ^ast.Node, depth: int, src: []byte, newline := fal case: fmt.panicf("Unhandled node kind: %T", n); } -}
\ No newline at end of file +} diff --git a/src/common/sha1.odin b/src/common/sha1.odin index 80a8765..67cbc4b 100644 --- a/src/common/sha1.odin +++ b/src/common/sha1.odin @@ -294,4 +294,4 @@ sha1_hash :: proc (data: []byte) -> [20]byte { copy(ret[:], result[:]); return ret; -}
\ No newline at end of file +} diff --git a/src/common/track_allocator.odin b/src/common/track_allocator.odin index 69c0e86..afb1de2 100644 --- a/src/common/track_allocator.odin +++ b/src/common/track_allocator.odin @@ -189,4 +189,4 @@ memleak_dump :: proc (memleak_alloc: mem.Allocator, dump_proc: proc (message: st log_dump :: proc (message: string, user_data: rawptr) { log.info(message); -}
\ No newline at end of file +} diff --git a/src/common/types.odin b/src/common/types.odin index 4cdfc24..ae8da35 100644 --- a/src/common/types.odin +++ b/src/common/types.odin @@ -24,4 +24,4 @@ Error :: enum WorkspaceFolder :: struct { name: string, uri: string, -}
\ No newline at end of file +} diff --git a/src/common/uri.odin b/src/common/uri.odin index b69ae92..b979634 100644 --- a/src/common/uri.odin +++ b/src/common/uri.odin @@ -155,4 +155,4 @@ decode_percent :: proc (value: string, allocator: mem.Allocator) -> (string, boo } return strings.to_string(builder), true; -}
\ No newline at end of file +} diff --git a/src/index/build.odin b/src/index/build.odin index 87f5bd1..47af974 100644 --- a/src/index/build.odin +++ b/src/index/build.odin @@ -139,4 +139,4 @@ log_error_handler :: proc (pos: tokenizer.Pos, msg: string, args: ..any) { log_warning_handler :: proc (pos: tokenizer.Pos, msg: string, args: ..any) { log.warnf("%v %v %v", pos, msg, args); -}
\ No newline at end of file +} diff --git a/src/index/clone.odin b/src/index/clone.odin index d3abcfe..a10d2e7 100644 --- a/src/index/clone.odin +++ b/src/index/clone.odin @@ -212,4 +212,4 @@ clone_node :: proc (node: ^ast.Node, allocator: mem.Allocator, unique_strings: ^ } return res; -}
\ No newline at end of file +} diff --git a/src/index/collector.odin b/src/index/collector.odin index 60bef9e..cd524f4 100644 --- a/src/index/collector.odin +++ b/src/index/collector.odin @@ -515,4 +515,4 @@ replace_package_alias_node :: proc (node: ^ast.Node, package_map: map[string]str case: log.warnf("Replace Unhandled node kind: %T", n); } -}
\ No newline at end of file +} diff --git a/src/index/file_index.odin b/src/index/file_index.odin index 7b98413..60a0228 100644 --- a/src/index/file_index.odin +++ b/src/index/file_index.odin @@ -1 +1 @@ -package index
\ No newline at end of file +package index diff --git a/src/index/indexer.odin b/src/index/indexer.odin index 3d9cb8c..1d21bf7 100644 --- a/src/index/indexer.odin +++ b/src/index/indexer.odin @@ -115,4 +115,4 @@ fuzzy_sort_interface :: proc (s: ^[dynamic]FuzzyResult) -> sort.Interface { s[i], s[j] = s[j], s[i]; }, }; -}
\ No newline at end of file +} diff --git a/src/index/memory_index.odin b/src/index/memory_index.odin index 3361ba1..159e01c 100644 --- a/src/index/memory_index.odin +++ b/src/index/memory_index.odin @@ -68,4 +68,4 @@ exists_in_scope :: proc (symbol_scope: string, scope: []string) -> bool { } return false; -}
\ No newline at end of file +} diff --git a/src/index/symbol.odin b/src/index/symbol.odin index 2e06e47..94ebbc5 100644 --- a/src/index/symbol.odin +++ b/src/index/symbol.odin @@ -135,4 +135,4 @@ get_symbol_id :: proc (str: string) -> uint { ret := common.sha1_hash(transmute([]byte)str); r := cast(^uint)slice.first_ptr(ret[:]); return r^; -}
\ No newline at end of file +} diff --git a/src/index/util.odin b/src/index/util.odin index b179a01..e3c6da4 100644 --- a/src/index/util.odin +++ b/src/index/util.odin @@ -165,4 +165,4 @@ build_string_node :: proc (node: ^ast.Node, builder: ^strings.Builder) { strings.write_string(builder, "]"); build_string(n.value, builder); } -}
\ No newline at end of file +} diff --git a/src/main.odin b/src/main.odin index c8587f2..555490d 100644 --- a/src/main.odin +++ b/src/main.odin @@ -109,4 +109,4 @@ main :: proc () { init_global_temporary_allocator(mem.megabytes(100)); run(&reader, &writer); -}
\ No newline at end of file +} diff --git a/src/server/action.odin b/src/server/action.odin index 44b3458..ba1b367 100644 --- a/src/server/action.odin +++ b/src/server/action.odin @@ -13,4 +13,4 @@ CodeActionClientCapabilities :: struct { CodeActionOptions :: struct { codeActionKinds: []CodeActionKind, resolveProvider: bool, -}
\ No newline at end of file +} diff --git a/src/server/analysis.odin b/src/server/analysis.odin index 8dc4509..43192ba 100644 --- a/src/server/analysis.odin +++ b/src/server/analysis.odin @@ -2493,4 +2493,4 @@ get_document_position_node :: proc (node: ^ast.Node, position_context: ^Document case: log.errorf("Unhandled node kind: %T", n); } -}
\ No newline at end of file +} diff --git a/src/server/background.odin b/src/server/background.odin index 359e7d7..3cd8064 100644 --- a/src/server/background.odin +++ b/src/server/background.odin @@ -7,4 +7,4 @@ package server import "shared:index" background_main :: proc () { -}
\ No newline at end of file +} diff --git a/src/server/completion.odin b/src/server/completion.odin index 54c8b26..a4eadb1 100644 --- a/src/server/completion.odin +++ b/src/server/completion.odin @@ -793,4 +793,4 @@ get_type_switch_Completion :: proc (ast_context: ^AstContext, position_context: } list.items = items[:]; -}
\ No newline at end of file +} diff --git a/src/server/documents.odin b/src/server/documents.odin index ab8b54d..7f92cb0 100644 --- a/src/server/documents.odin +++ b/src/server/documents.odin @@ -435,4 +435,4 @@ parse_document :: proc (document: ^Document, config: ^common.Config) -> ([]Parse document.imports = imports[:]; return current_errors[:], true; -}
\ No newline at end of file +} diff --git a/src/server/format.odin b/src/server/format.odin index 3ad492c..40bdaa5 100644 --- a/src/server/format.odin +++ b/src/server/format.odin @@ -53,4 +53,4 @@ get_complete_format :: proc (document: ^Document) -> ([]TextEdit, bool) { */ return {}, false; -}
\ No newline at end of file +} diff --git a/src/server/hover.odin b/src/server/hover.odin index 08d49ca..30a8fb0 100644 --- a/src/server/hover.odin +++ b/src/server/hover.odin @@ -135,4 +135,4 @@ get_hover_information :: proc (document: ^Document, position: common.Position) - } return hover, true; -}
\ No newline at end of file +} diff --git a/src/server/log.odin b/src/server/log.odin index 77816a1..1527fa2 100644 --- a/src/server/log.odin +++ b/src/server/log.odin @@ -44,4 +44,4 @@ lsp_logger_proc :: proc (logger_data: rawptr, level: log.Level, text: string, op }; send_notification(notification, data.writer); -}
\ No newline at end of file +} diff --git a/src/server/reader.odin b/src/server/reader.odin index a3d5937..7679db7 100644 --- a/src/server/reader.odin +++ b/src/server/reader.odin @@ -57,4 +57,4 @@ read_sized :: proc (reader: ^Reader, data: []u8) -> bool { } return true; -}
\ No newline at end of file +} diff --git a/src/server/requests.odin b/src/server/requests.odin index 5a02fb3..0dc9b7c 100644 --- a/src/server/requests.odin +++ b/src/server/requests.odin @@ -1030,4 +1030,4 @@ request_hover :: proc (task: ^common.Task) { id = id); send_response(response, writer); -}
\ No newline at end of file +} diff --git a/src/server/response.odin b/src/server/response.odin index 1ef7484..d5d3e7b 100644 --- a/src/server/response.odin +++ b/src/server/response.odin @@ -64,4 +64,4 @@ send_error :: proc (response: ResponseMessageError, writer: ^Writer) -> bool { } return true; -}
\ No newline at end of file +} diff --git a/src/server/semantic_tokens.odin b/src/server/semantic_tokens.odin index 7f238d3..74406e5 100644 --- a/src/server/semantic_tokens.odin +++ b/src/server/semantic_tokens.odin @@ -576,4 +576,4 @@ get_locals_at :: proc (function: ^ast.Node, position: ^ast.Node, ast_context: ^A }; get_locals(ast_context.file, function, ast_context, &document_position); -}
\ No newline at end of file +} diff --git a/src/server/types.odin b/src/server/types.odin index 2ee477b..22a8451 100644 --- a/src/server/types.odin +++ b/src/server/types.odin @@ -346,4 +346,4 @@ HoverParams :: struct { Hover :: struct { contents: MarkupContent, range: common.Range, -}
\ No newline at end of file +} diff --git a/src/server/unmarshal.odin b/src/server/unmarshal.odin index 77459bf..c61b7c8 100644 --- a/src/server/unmarshal.odin +++ b/src/server/unmarshal.odin @@ -146,4 +146,4 @@ unmarshal :: proc (json_value: json.Value, v: any, allocator: mem.Allocator) -> } return .None; -}
\ No newline at end of file +} diff --git a/src/server/workspace.odin b/src/server/workspace.odin index f275077..abb4e43 100644 --- a/src/server/workspace.odin +++ b/src/server/workspace.odin @@ -1 +1 @@ -package server
\ No newline at end of file +package server diff --git a/src/server/writer.odin b/src/server/writer.odin index 6a1b8ed..4e9ebae 100644 --- a/src/server/writer.odin +++ b/src/server/writer.odin @@ -32,4 +32,4 @@ write_sized :: proc (writer: ^Writer, data: []byte) -> bool { } return true; -}
\ No newline at end of file +} diff --git a/src/session/capture.odin b/src/session/capture.odin index e71c79f..ab87616 100644 --- a/src/session/capture.odin +++ b/src/session/capture.odin @@ -1 +1 @@ -package session
\ No newline at end of file +package session diff --git a/src/session/replay.odin b/src/session/replay.odin index 0519ecb..ab87616 100644 --- a/src/session/replay.odin +++ b/src/session/replay.odin @@ -1 +1 @@ -
\ No newline at end of file +package session |