returns imp_funcs, a dictionary with filepath keys that contains 
    lists of function definition nodes that were imported using
     from __ import __ style syntax. also returns imp_classes, which 
    is the same for class definition nodes.

def matchImpObjStrs(fdefs,imp_obj_strs,cdefs):
    '''returns imp_funcs, a dictionary with filepath keys that contains 
    lists of function definition nodes that were imported using
     from __ import __ style syntax. also returns imp_classes, which 
    is the same for class definition nodes.'''
    imp_funcs=dict()
    imp_classes=dict()
    for source in imp_obj_strs:
        if not imp_obj_strs[source]:
            continue
        imp_funcs[source]=[]
        imp_classes[source]=[]
        for (mod,func) in imp_obj_strs[source]:
            if mod not in fdefs:
                #print(mod+" is not part of the project.")
                continue
            if func=='*':
                all_fns = [x for x in fdefs[mod] if x.name!='body']
                imp_funcs[source] += all_fns
                all_cls = [x for x in cdefs[mod]]
                imp_classes[source] += all_cls
            else:
                fn_node = [x for x in fdefs[mod] if x.name==func]
                cls_node = [x for x in cdefs[mod] if x.name==func]
                #assert len(fn_node) in [1,0]
                #assert len(cls_node) in [1,0]
                if cls_node:
                    imp_classes[source] += cls_node
                if fn_node:
                    imp_funcs[source] += fn_node
                if not fn_node and not cls_node:
                    pass
                    #print(func+' not found in function and class definitions.')
    return imp_funcs,imp_classes