Skip to content
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

[CodeStyle][Typos][K-[2-4]] Fix typo (keyward, Keyward) #70356

Merged
merged 3 commits into from
Dec 21, 2024
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
6 changes: 2 additions & 4 deletions _typos.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ cll = 'cll'
dout = "dout"
eles = 'eles'
grad = "grad"
kinf = 'kinf'
kow = 'kow'
lod = "lod"
Nce = "Nce"
Nd = "Nd"
Expand Down Expand Up @@ -262,10 +264,6 @@ interated = 'interated'
Iteraion = 'Iteraion'
IIT = 'IIT'
iy = 'iy'
Keyward = 'Keyward'
keyward = 'keyward'
kinf = 'kinf'
kow = 'kow'
lable = 'lable'
lamda = 'lamda'
labmda = 'labmda'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -487,7 +487,7 @@ struct PirToPyCodeConverterHelper {
const auto& args = block.args();
return std::find(args.begin(), args.end(), value) != args.end();
};
const auto IsBlockKeywardArg = [&](pir::Value value) {
const auto IsBlockKeywordArg = [&](pir::Value value) {
const auto& kwargs = block.kwargs();
for (const auto& [_, kwarg] : kwargs) {
if (kwarg == value) return true;
Expand All @@ -499,7 +499,7 @@ struct PirToPyCodeConverterHelper {
if (std::find(inputs.begin(), inputs.end(), value) != inputs.end())
continue;
if (IsBlockPositionalArg(value)) continue;
if (IsBlockKeywardArg(value)) continue;
if (IsBlockKeywordArg(value)) continue;
inputs.push_back(value);
}
return inputs;
Expand Down
4 changes: 2 additions & 2 deletions python/paddle/jit/dy2static/program_translator.py
Original file line number Diff line number Diff line change
Expand Up @@ -527,7 +527,7 @@ def __call__(self, *args: _InputT.args, **kwargs: _InputT.kwargs) -> _RetT:

Args:
*args(tuple): tuple of all input arguments from original decorated function.
**kwargs(dict): dict of all input keyward arguments from original decorated function.
**kwargs(dict): dict of all input keyword arguments from original decorated function.

Return:
Outputs of decorated function.
Expand Down Expand Up @@ -576,7 +576,7 @@ def _call_dygraph_function(

Args:
*args(tuple): tuple of all input arguments from original decorated function.
**kwargs(dict): dict of all input keyward arguments from original decorated function.
**kwargs(dict): dict of all input keyword arguments from original decorated function.

Return:
Outputs of dygraph function.
Expand Down