Skip to content

Commit

Permalink
refactor: simplify code #24
Browse files Browse the repository at this point in the history
  • Loading branch information
phodal committed Jan 6, 2024
1 parent 8097334 commit e8f9f7d
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -173,8 +173,8 @@ open class CFullIdentListener(fileName: String) : CAstBaseListener() {
// handle for a pointer
val firstParameter = currentFunction.Parameters[0]
if (firstParameter.TypeType.endsWith('*')) {
val pointerIndex = firstParameter.TypeType.length - 1
val baseType = firstParameter.TypeType.substring(0, pointerIndex)
val baseType = firstParameter.TypeType.removeSuffix("*")

structMap.getOrPut(baseType) {
CodeDataStruct(NodeName = baseType)
}.let {
Expand Down

0 comments on commit e8f9f7d

Please sign in to comment.