Q:

smali logging an util/collection ArrayList

i want to log a ArrayList that is typed as util/collection but i cant figure out what the right syntax is. For logging it directly orconverting it to string in smali.
I tried to use the iglogger but when i recompile with the iglogger inserted it throws an error saying it cant smali the iglogger.smali.
Is there a documentation for smali logging out there?I can only find it for logging a string:
invoke-static {v0},Landroid/util/Log;->d(Ljava/lang/String;)I

Thank You

A:

If you want to use IGLogger, you need to invoke IGLogger's methods. Currently you're invoking Android's Log class.
If you want to keep using IGLogger, you need this:
invoke-static {v0}, Lcom/whatever/package/holds/iglogger;->d(Ljava/lang/String;)I # where v0 is a String. If v0 is your ArrayList you need to call toString() on it and store that result first

However, it really makes more sense to just use Anroid's Log class:
invoke-virtual {v0}, Ljava/util/ArrayList;->toString()Ljava/lang/String; # where v0 is your ArrayList

move-result-object v1

const-string/jumbo v2, "SomeTag"

invoke-static {v2, v1}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;)I

