Skip to content

Commit

Permalink
Merge pull request #83 from kevaundray/patch-1
Browse files Browse the repository at this point in the history
chore: csharp methods have the same visibility as structures and the class
  • Loading branch information
neuecc authored Jul 8, 2024
2 parents c49da09 + 42275bc commit 068e1e7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions csbindgen/src/emitter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ pub fn emit_csharp(
.as_str(),
);
method_list_string
.push_str(format!(" public {delegate_method};\n\n").as_str());
.push_str(format!(" {accessibility} {delegate_method};\n\n").as_str());
}
}

Expand All @@ -149,7 +149,7 @@ pub fn emit_csharp(
.as_str(),
);
method_list_string
.push_str(format!(" public {delegate_method};\n\n").as_str());
.push_str(format!(" {accessibility} {delegate_method};\n\n").as_str());
}
}

Expand Down Expand Up @@ -196,7 +196,7 @@ pub fn emit_csharp(
method_list_string.push_str_ln(" [return: MarshalAs(UnmanagedType.U1)]");
}
method_list_string.push_str_ln(
format!(" public static extern {return_type} {method_prefix}{method_name}({parameters});").as_str(),
format!(" {accessibility} static extern {return_type} {method_prefix}{method_name}({parameters});").as_str(),
);
method_list_string.push('\n');
}
Expand Down

0 comments on commit 068e1e7

Please sign in to comment.