pChainCtrl
pChainName
pDef
pChainCtrl
pArgs
pChainCtrl
pChainCtrl
name
pChainTable
These are arguments of few functions,Need to add them to a function template in front of "@param[in ]"
TEMPLATE
/**
********************************************************************************
* @fn
* @brief
* @param[in ]
* @return
********************************************************************************
*/
MY CODE
use strict;
use warnings;
open(FILE3,"< functions2.txt")or die $!;
my @array1 = <FILE3>;
foreach my $arg (@array1){
open(my $FILE4,"+< function_template.txt")or die $!;;
seek( $FILE4, 197, 0); // takes pointer infront of @param[in ]
chomp $arg;
print $FILE4 "$arg";
close($FILE4);
}
close(FILE3);
It adds arguments one by one.
I need to add the each set of arguments to file template which will be copied elsewhere(I have code for that) and then move on to next set of arguments
OUTPUT REQUIRED
/**
********************************************************************************
* @fn
* @brief
* @param[in ] pChainCtrl
pChainName
pDef
* @return
********************************************************************************
*/