(CommandList children: [ (FuncDef name: _smf_complete_fmri body: (BraceGroup children: [ (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:cur) op: Equal rhs: {(DQ ($ VSub_Number '$1'))} spids: [74] ) (assign_pair lhs: (LhsName name:prefix) op: Equal rhs: {(DQ ($ VSub_Number '$2'))} spids: [79] ) ] spids: [72] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs:(LhsName name:cur_prefix) op:Equal spids:[87]) (assign_pair lhs:(LhsName name:fmri) op:Equal spids:[89]) (assign_pair lhs: (LhsName name:fmri_list) op: Equal rhs: {(DQ )} spids: [91] ) ] spids: [85] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs:(LhsName name:exact_mode) op:Equal spids:[98]) (assign_pair lhs:(LhsName name:pattern) op:Equal spids:[100]) ] spids: [96] ) (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolBinary op_id: BoolBinary_GlobDEqual left: {(DQ ($ VSub_Name '$cur'))} right: {($ VSub_Name '$prefix') (Lit_Other '*')} ) ) terminator: <Op_Semi ';'> ) ] action: [ (AndOr ops: [Op_DAmp] children: [ (DBracket expr: (BoolBinary op_id: BoolBinary_GlobDEqual left: {(DQ ($ VSub_Name '$cur'))} right: {($ VSub_Name '$prefix')} ) ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:cur) op: PlusEqual rhs: {(DQ (/))} spids: [137] ) ] spids: [137] ) ] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:pattern) op: Equal rhs: {(DQ ($ VSub_Name '$cur') ('*'))} spids: [143] ) ] spids: [143] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:exact_mode) op: Equal rhs: {(1)} spids: [150] ) ] spids: [150] ) ] spids: [16777215 120] ) ] else_action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:pattern) op: Equal rhs: {(DQ ($ VSub_Name '$prefix') ('*/') ($ VSub_Name '$cur') ('*'))} spids: [157] ) ] spids: [157] ) ] spids: [154 166] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:cur_prefix) op: Equal rhs: { (DQ (BracedVarSub token: <VSub_Name cur> suffix_op: (StringUnary op_id: VOp1_Percent arg_word: { (DQ (BracedVarSub token: <VSub_Name cur> suffix_op: (StringUnary op_id: VOp1_DPound arg_word: {('*') (Lit_Slash /)} ) spids: [176 181] ) ) } ) spids: [172 183] ) ) } spids: [170] ) ] spids: [170] ) (ForEach iter_name: fmri iter_words: [ { (CommandSubPart command_list: (CommandList children: [ (SimpleCommand words: [{(svcs)} {(-H)} {(-o)} {(FMRI)} {(DQ ($ VSub_Name '$pattern'))}] redirects: [ (Redir op_id: Redir_Great fd: 2 arg_word: {(/dev/null)} spids: [207] ) ] ) ] ) left_token: <Left_CommandSub '$('> spids: [194 209] ) } ] do_arg_iter: F body: (DoGroup children: [ (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:fmri_part_list) op: Equal spids: [217] ) (assign_pair lhs: (LhsName name:fmri_part) op: Equal spids: [219] ) ] spids: [215] ) (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolUnary op_id: BoolUnary_z child: {(DQ ($ VSub_Name '$exact_mode'))} ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:fmri) op: Equal rhs: { (BracedVarSub token: <VSub_Name fmri> suffix_op: (StringUnary op_id: VOp1_Pound arg_word: {($ VSub_Name '$prefix') (Lit_Slash /)} ) spids: [239 244] ) } spids: [238] ) ] spids: [238] ) (Sentence child: (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:OIFS) op: Equal rhs: {(DQ ($ VSub_Name '$IFS'))} spids: [262] ) ] spids: [260] ) terminator: <Op_Semi ';'> ) (Sentence child: (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:IFS) op: Equal rhs: {(DQ (/))} spids: [268] ) ] spids: [268] ) terminator: <Op_Semi ';'> ) (Sentence child: (C {(set)} {(--)} {($ VSub_Name '$fmri')}) terminator: <Op_Semi ';'> ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:IFS) op: Equal rhs: {(DQ ($ VSub_Name '$OIFS'))} spids: [281] ) ] spids: [281] ) (Case to_match: {($ VSub_Pound '$#')} arms: [ (case_arm pat_list: [{(1)}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:fmri_part_list) op: Equal rhs: {(DQ (' ') ($ VSub_Number '$1'))} spids: [297] ) ] spids: [297] ) ] spids: [294 295 302 16777215] ) (case_arm pat_list: [{(2)}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:fmri_part_list) op: Equal rhs: { (DQ (' ') ($ VSub_Number '$2') (' ') ($ VSub_Number '$1') (/) ($ VSub_Number '$2') ) } spids: [308] ) ] spids: [308] ) ] spids: [305 306 317 16777215] ) (case_arm pat_list: [{(3)}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:fmri_part_list) op: Equal rhs: { (DQ (' ') ($ VSub_Number '$3') (' ') ($ VSub_Number '$2') (/) ($ VSub_Number '$3') (' ') ($ VSub_Number '$1') (/) ($ VSub_Number '$2') (/) ($ VSub_Number '$3') ) } spids: [323] ) ] spids: [323] ) ] spids: [320 321 338 16777215] ) (case_arm pat_list: [{(4)}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:fmri_part_list) op: Equal rhs: { (DQ (' ') ($ VSub_Number '$4') (' ') ($ VSub_Number '$3') (/) ($ VSub_Number '$4') (' ') ($ VSub_Number '$2') (/) ($ VSub_Number '$3') (/) ($ VSub_Number '$4') (' ') ($ VSub_Number '$1') (/) ($ VSub_Number '$2') (/) ($ VSub_Number '$3') (/) ($ VSub_Number '$4') ) } spids: [344] ) ] spids: [344] ) ] spids: [341 342 367 16777215] ) ] spids: [287 291 370] ) ] spids: [16777215 235] ) ] else_action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:fmri_part_list) op: Equal rhs: {(DQ ($ VSub_Name '$fmri'))} spids: [376] ) ] spids: [376] ) ] spids: [373 382] ) (ForEach iter_name: fmri_part iter_words: [{($ VSub_Name '$fmri_part_list')}] do_arg_iter: F body: (DoGroup children: [ (AndOr ops: [Op_DPipe] children: [ (DBracket expr: (BoolBinary op_id: BoolBinary_GlobDEqual left: {(DQ ($ VSub_Name '$fmri_part'))} right: {($ VSub_Name '$cur') (Lit_Other '*')} ) ) (ControlFlow token: <ControlFlow_Continue continue> ) ] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:first_part) op: Equal rhs: { (BracedVarSub token: <VSub_Name fmri_part> suffix_op: (StringUnary op_id: VOp1_Pound arg_word: {($ VSub_Name '$cur_prefix')} ) spids: [427 431] ) } spids: [426] ) ] spids: [424] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:first_part) op: Equal rhs: {($ VSub_Name '$cur_prefix') (BracedVarSub token: <VSub_Name first_part> suffix_op: (StringUnary op_id: VOp1_DPercent arg_word: {(Lit_Slash /) ('*')} ) spids: [436 441] ) } spids: [434] ) ] spids: [434] ) (AndOr ops: [Op_DAmp] children: [ (DBracket expr: (BoolBinary op_id: BoolBinary_GlobNEqual left: {(DQ ($ VSub_Name '$first_part'))} right: {(DQ ($ VSub_Name '$fmri_part'))} ) ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:first_part) op: PlusEqual rhs: {(DQ (/))} spids: [460] ) ] spids: [460] ) ] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:fmri_list) op: PlusEqual rhs: {(DQ (' ') ($ VSub_Name '$first_part'))} spids: [466] ) ] spids: [466] ) ] spids: [403 473] ) spids: [399 401] ) ] spids: [212 476] ) spids: [193 210] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:COMPREPLY) op: Equal rhs: {(ArrayLiteralPart words:[{($ VSub_Name '$fmri_list')}])} spids: [480] ) ] spids: [480] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:i) op: Equal rhs: { (BracedVarSub token: <VSub_Name COMPREPLY> prefix_op: VSub_Pound bracket_op: (WholeArray op_id:Arith_Star) spids: [508 514] ) } spids: [507] ) ] spids: [505] ) (If arms: [ (if_arm cond: [ (Sentence child: (AndOr ops: [Op_DAmp] children: [ (DBracket expr: (BoolBinary op_id: BoolBinary_gt left: {($ VSub_Name '$i')} right: {(0)} ) ) (DBracket expr: (BoolBinary op_id: BoolBinary_GlobDEqual left: { (DQ (BracedVarSub token: <VSub_Name COMPREPLY> bracket_op: (ArrayIndex expr: (ArithWord w: { (ArithSubPart anode: (UnaryAssign op_id: Arith_DMinus child: (LhsName name:i) ) spids: [537 541] ) } ) ) spids: [534 543] ) ) } right: {(Lit_Other '*') (/)} ) ) ] ) terminator: <Op_Semi ';'> ) ] action: [ (While cond: [ (Sentence child: (DBracket expr: (BoolBinary op_id: BoolBinary_ne left: {($ VSub_Name '$i')} right: {(0)} ) ) terminator: <Op_Semi ';'> ) ] body: (DoGroup children: [ (AndOr ops: [Op_DAmp] children: [ (DBracket expr: (BoolBinary op_id: BoolBinary_GlobNEqual left: { (DQ (BracedVarSub token: <VSub_Name COMPREPLY> bracket_op: (ArrayIndex expr: (ArithWord w:{($ VSub_Name '$i')}) ) spids: [580 585] ) ) } right: { (DQ (BracedVarSub token: <VSub_Name COMPREPLY> bracket_op: (ArrayIndex expr: (ArithWord w: { (ArithSubPart anode: (ArithBinary op_id: Arith_Minus left: (ArithVarRef name:i) right: (ArithWord w:{(Lit_Digits 1)}) ) spids: [594 601] ) } ) ) spids: [591 603] ) ) } ) ) (ControlFlow token: <ControlFlow_Break break> ) ] ) (DParen child: (UnaryAssign op_id:Node_PostDMinus child:(LhsName name:i)) ) ] spids: [574 620] ) ) (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolBinary op_id: BoolBinary_eq left: {($ VSub_Name '$i')} right: {(0)} ) ) terminator: <Op_Semi ';'> ) ] action: [ (C {(_smf_complete_fmri)} { (DQ (BracedVarSub token: <VSub_Name COMPREPLY> bracket_op: (ArrayIndex expr:(ArithWord w:{(Lit_Digits 0)})) spids: [642 647] ) ) } {(DQ ($ VSub_Name '$prefix'))} ) (ControlFlow token: <ControlFlow_Return return> arg_word: {(0)} ) ] spids: [16777215 636] ) ] spids: [16777215 660] ) ] spids: [16777215 554] ) ] spids: [16777215 663] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:colonprefixes) op: Equal rhs: { (BracedVarSub token: <VSub_Name cur> suffix_op: (StringUnary op_id: VOp1_Percent arg_word: { (DQ (BracedVarSub token: <VSub_Name cur> suffix_op: (StringUnary op_id:VOp1_DPound arg_word:{('*:')}) spids: [686 690] ) ) } ) spids: [682 692] ) } spids: [681] ) ] spids: [679] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:i) op: Equal rhs: { (BracedVarSub token: <VSub_Name COMPREPLY> prefix_op: VSub_Pound bracket_op: (WholeArray op_id:Arith_Star) spids: [698 704] ) } spids: [697] ) ] spids: [695] ) (While cond: [ (Sentence child: (C {(Lit_Other '[')} { (ArithSubPart anode: (UnaryAssign op_id:Arith_DMinus child:(LhsName name:i)) spids: [711 715] ) } {(-ge)} {(0)} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] body: (DoGroup children: [ (C {(COMPREPLY) (Lit_Other '[') ($ VSub_Name '$i') (Lit_Other ']') (Lit_Other '=') (BracedVarSub token: <VSub_Name COMPREPLY> bracket_op: (ArrayIndex expr:(ArithWord w:{($ VSub_Name '$i')})) suffix_op: (StringUnary op_id: VOp1_Pound arg_word: {(DQ ($ VSub_Name '$colonprefixes'))} ) spids: [732 741] ) } ) ] spids: [724 744] ) ) ] spids: [69] ) spids: [64 68] ) (AndOr ops: [Op_DAmp] children: [ (FuncDef name: _svcadm body: (BraceGroup children: [ (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs:(LhsName name:cur) op:Equal spids:[759]) (assign_pair lhs:(LhsName name:prev) op:Equal spids:[761]) (assign_pair lhs:(LhsName name:words) op:Equal spids:[763]) (assign_pair lhs:(LhsName name:cword) op:Equal spids:[765]) ] spids: [757] ) (AndOr ops: [Op_DPipe] children: [ (C {(_init_completion)} {(-n)} {(Lit_Other ':')}) (ControlFlow token:<ControlFlow_Return return>) ] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:command_list) op: Equal rhs: {(DQ ('enable disable restart refresh clear mark milestone'))} spids: [783] ) ] spids: [781] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs:(LhsName name:command) op:Equal spids:[791]) (assign_pair lhs:(LhsName name:i) op:Equal spids:[793]) ] spids: [789] ) (ForExpr init: (BinaryAssign op_id: Arith_Equal left: (LhsName name:i) right: (ArithWord w:{(Lit_Digits 1)}) ) cond: (ArithBinary op_id: Arith_Less left: (ArithVarRef name:i) right: (ArithWord w:{($ VSub_Name '$cword')}) ) update: (UnaryAssign op_id:Node_PostDPlus child:(LhsName name:i)) body: (DoGroup children: [ (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolBinary op_id: BoolBinary_GlobDEqual left: { (BracedVarSub token: <VSub_Name words> bracket_op: (ArrayIndex expr:(ArithVarRef name:i)) spids: [827 832] ) } right: {(ExtGlobPart op:<ExtGlob_At '@('> spids:[836 850])} ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:command) op: Equal rhs: { (BracedVarSub token: <VSub_Name words> bracket_op: (ArrayIndex expr:(ArithVarRef name:i)) spids: [859 864] ) } spids: [858] ) ] spids: [858] ) ] spids: [16777215 855] ) ] spids: [16777215 867] ) ] spids: [820 870] ) ) (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolUnary op_id:BoolUnary_z child:{(DQ ($ VSub_Name '$command'))}) ) terminator: <Op_Semi ';'> ) ] action: [ (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolBinary op_id: BoolBinary_GlobDEqual left: {(${ VSub_Name cur)} right: {(-) (Lit_Other '*')} ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:COMPREPLY) op: Equal rhs: { (ArrayLiteralPart words: [ { (CommandSubPart command_list: (CommandList children: [ (C {(compgen)} {(-W)} {(DQ (-v))} {(--)} {(${ VSub_Name cur)} ) ] ) left_token: <Left_CommandSub '$('> spids: [913 927] ) } ] ) } spids: [910] ) ] spids: [910] ) ] spids: [16777215 907] ) ] else_action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:COMPREPLY) op: Equal rhs: { (ArrayLiteralPart words: [ { (CommandSubPart command_list: (CommandList children: [ (C {(compgen)} {(-W)} {(DQ ($ VSub_Name '$command_list'))} {(--)} {(${ VSub_Name cur)} ) ] ) left_token: <Left_CommandSub '$('> spids: [938 952] ) } ] ) } spids: [935] ) ] spids: [935] ) ] spids: [932 957] ) ] spids: [16777215 887] ) ] else_action: [ (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolBinary op_id: BoolBinary_GlobDEqual left: {(${ VSub_Name cur)} right: {(-) (Lit_Other '*')} ) ) terminator: <Op_Semi ';'> ) ] action: [ (Case to_match: {(DQ ($ VSub_Name '$command'))} arms: [ (case_arm pat_list: [{(enable)}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:COMPREPLY) op: Equal rhs: { (ArrayLiteralPart words: [ { (CommandSubPart command_list: (CommandList children: [ (C {(compgen)} {(-W)} {(DQ ('-r -s -t'))} {(--)} {(${ VSub_Name cur)} ) ] ) left_token: <Left_CommandSub '$('> spids: [998 1012] ) } ] ) } spids: [995] ) ] spids: [995] ) ] spids: [991 992 1015 16777215] ) (case_arm pat_list: [{(disable)}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:COMPREPLY) op: Equal rhs: { (ArrayLiteralPart words: [ { (CommandSubPart command_list: (CommandList children: [ (C {(compgen)} {(-W)} {(DQ ('-s -t'))} {(--)} {(${ VSub_Name cur)} ) ] ) left_token: <Left_CommandSub '$('> spids: [1025 1039] ) } ] ) } spids: [1022] ) ] spids: [1022] ) ] spids: [1018 1019 1042 16777215] ) (case_arm pat_list: [{(mark)}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:COMPREPLY) op: Equal rhs: { (ArrayLiteralPart words: [ { (CommandSubPart command_list: (CommandList children: [ (C {(compgen)} {(-W)} {(DQ ('-I -t'))} {(--)} {(${ VSub_Name cur)} ) ] ) left_token: <Left_CommandSub '$('> spids: [1052 1066] ) } ] ) } spids: [1049] ) ] spids: [1049] ) ] spids: [1045 1046 1069 16777215] ) (case_arm pat_list: [{(milestone)}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:COMPREPLY) op: Equal rhs: { (ArrayLiteralPart words: [ { (CommandSubPart command_list: (CommandList children: [ (C {(compgen)} {(-W)} {(DQ (-d))} {(--)} {(${ VSub_Name cur)} ) ] ) left_token: <Left_CommandSub '$('> spids: [1079 1093] ) } ] ) } spids: [1076] ) ] spids: [1076] ) ] spids: [1072 1073 1096 16777215] ) ] spids: [982 988 1099] ) ] spids: [16777215 979] ) ] else_action: [ (If arms: [ (if_arm cond: [ (Sentence child: (AndOr ops: [Op_DAmp] children: [ (DBracket expr: (BoolBinary op_id: BoolBinary_GlobDEqual left: {(DQ ($ VSub_Name '$command'))} right: {(DQ (mark))} ) ) (DBracket expr: (BoolBinary op_id: BoolBinary_GlobNEqual left: {(DQ ($ VSub_Name '$prev'))} right: { (ExtGlobPart op: <ExtGlob_At '@('> spids: [1131 1135] ) } ) ) ] ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:COMPREPLY) op: Equal rhs: { (ArrayLiteralPart words: [ { (CommandSubPart command_list: (CommandList children: [ (C {(compgen)} {(-W)} {(DQ ('degraded maintenance'))} {(--)} {(${ VSub_Name cur)} ) ] ) left_token: <Left_CommandSub '$('> spids: [1146 1160] ) } ] ) } spids: [1143] ) ] spids: [1143] ) ] spids: [16777215 1140] ) (if_arm cond: [ (Sentence child: (DBracket expr: (BoolBinary op_id: BoolBinary_GlobDEqual left: {(DQ ($ VSub_Name '$command'))} right: {(DQ (milestone))} ) ) terminator: <Op_Semi ';'> ) ] action: [ (C {(_smf_complete_fmri)} {(DQ (${ VSub_Name cur))} {(DQ ('svc:/milestone'))} ) ] spids: [1165 1182] ) ] else_action: [ (C {(_smf_complete_fmri)} {(DQ (${ VSub_Name cur))} {(DQ ('svc:'))}) ] spids: [1198 1214] ) ] spids: [1102 1217] ) ] spids: [960 1220] ) ] spids: [754] ) spids: [749 753] ) (C {(complete)} {(-F)} {(_svcadm)} {(svcadm)}) ] ) ] )