fix ada filename mixedcase with - object oriented
Derived types use caracter '.' in package name. But in the filename dot are replaced by '-' . For exemple : ```ada package Mother_Package.Daughter_Package is -- ... end Mother_Package.Daughter_Package; ``` is in a file named : Mother_Package-Daughter_Package.ads So function ada_case(word) change the '-' in filename to dot in the package name with mixedcase.
This commit is contained in:
parent
8c052b8975
commit
4f498954ab
@ -5,7 +5,9 @@ global !p
|
||||
def ada_case(word):
|
||||
out = word[0].upper()
|
||||
for i in range(1, len(word)):
|
||||
if word[i - 1] == '_':
|
||||
if word[i] == '-':
|
||||
out = out + '.'
|
||||
elif word[i - 1] == '_' or word[i - 1] == '-':
|
||||
out = out + word[i].upper()
|
||||
else:
|
||||
out = out + word[i]
|
||||
|
Loading…
Reference in New Issue
Block a user