8000 Fix postprocess by kkoomen · Pull Request #604 · kkoomen/vim-doge · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Fix postprocess #604

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Aug 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion helper/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion helper/src/cpp/parser.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ impl<'a> BaseParser for CppParser<'a> {
break;
}

new_line -= 1;
new_line = sibling_node.start_position().row + 1;
temp_node = sibling_node;
} else {
break;
Expand Down
2 changes: 1 addition & 1 deletion helper/src/rust/parser.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ impl<'a> BaseParser for RustParser<'a> {
break;
}

new_line -= 1;
new_line = sibling_node.start_position().row + 1;
temp_node = sibling_nod 8000 e;
} else {
break;
Expand Down
11 changes: 9 additions & 2 deletions test/filetypes/cpp/auto-functions.vader
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,17 @@ Expect cpp (generated comment with @brief, @tparam, @param and @return tags):
# Auto-functions with parameters with type hints using return type 'auto'
# ==============================================================================
Given cpp (auto-function with parameters with advanced type hints using return type 'auto'):
template<class T, class U>
template<
class T,
class U
>
auto add(T t, U u)
{
//
}

Do (trigger doge):
:5\<CR>
\<C-d>

Expect cpp (generated comment with @brief, @tparam, @param and @return tags):
Expand All @@ -48,7 +52,10 @@ Expect cpp (generated comment with @brief, @tparam, @param and @return tags):
* @param[[TODO:direction]] t [TODO:description]
* @param[[TODO:direction]] u [TODO:description]
*/
template<class T, class U>
template<
class T,
class U
>
auto add(T t, U u)
{
//
Expand Down
12 changes: 9 additions & 3 deletions test/filetypes/rust/functions.vader
Original file line number Diff line number Diff line change
Expand Up @@ -64,14 +64,17 @@ Expect rust (generated comments with Arguments and Examples sections):
# ==============================================================================
Given rust (impl methods with Errors and Safety section):
#[debug]
#[macro_export]
#[foo(
bar=1,
baz=2
)]
pub unsafe fn foo(foo: usize) -> Result<(), FooError> {
fs::read_to_string("file.txt")
.unwrap_or_else(|err| panic!("Failed to read filepath: {:?}", err));
}

Do (trigger doge):
:3\<CR>
:6\<CR>
\<C-d>

Expect rust (generated comments with Arguments, Safety, Errors and Examples sections):
Expand Down Expand Up @@ -99,7 +102,10 @@ Expect rust (generated comments with Arguments, Safety, Errors and Examples sect
/// [TODO:write some example code]
/// ```
#[debug]
#[macro_export]
#[foo(
bar=1,
baz=2
)]
pub unsafe fn foo(foo: usize) -> Result<(), FooError> {
fs::read_to_string("file.txt")
.unwrap_or_else(|err| panic!("Failed to read filepath: {:?}", err));
Expand Down
0